...
Date | Individual | Progress | Concerns | ||
sept. 18 | Jess | Got CANable adapters working, updated verified mcp2515 works on MCI rev 5 that has the CANable adapter soldered to it. Questions:
| CANable adapter should probably not be soldered to the board in future. Also had to sacrifice a system CAN terminating resistor in the debug process, sorry Blockers:
| ||
sept 21 - 9am | Aashmika + Kristen |
|
| ||
sept 25 | Jess | Figured out how to connect steering stalk to rev 4, tested some firmware
|
| ||
Oct 11 | Jess | Found source of CC DECR not working on steering. We implement interrupts in firmware using the STM32 external event input interface, which only has 16 lines. We set this up in firmware so we can register an interrupt on each pin number, e.g. PB1 and PA2 works but if you register PB1 then PA1 registering for PA1 will fail. The regen button and the CC on/off button still don’t consistently trigger interrupts. ADC values for CC on/off are consistently ~1600, with no noticeable variability when the button is pressed. The interrupt never triggers. ADC values for regen toggle are ~1600 when the button is unpressed, then they jump to ~1800 when the button is pressed. Occasionally the interrupt triggers, but not consistently. To have minicom ADC and interrupt logging, use branch Couldn’t find the center console board. Tried switching cables for driver display, but it seems pretty busted. |
| ||
Oct. 12 🦃 | Jess | ===== DAY ===== Tested MCI with a bugfix from MPXE validation, the flow for setting drive output → getting pedal commands seems to work now. Precharge used to flip PB0 properly, but not PA10 (I was told this was because it only flips PA10 if the relay is connected, which it wasn’t, so this was expected behaviour). Now, precharge doesn’t seem to flip either, but this is under progress by hardware at the moment so hopefully will be fixed soon. Aside from that, MCI counts as validated. ===== EVENING ===== Steering: decided it’s not worth fixing it in hardware (too many jumpers required), but stuff sorta works intermittently. Functionality confirmed in firmware, but need to fix up actual project to work in all functionality. Decided DRL toggle is the lane assist button (PA6) and horn (PB1) pin needs to change to allow CC DECR (PA1) to have an interrupt. MCI: drive fsm + pedal → mcp2515 output flow all works. Precharge logic being validated by hardware. Power distro: learned how to set it up for testing, will work on it tomorrow w/ Ryan. Power select: things seem ok, seems like there’s a lot of problems in hardware. Some preliminary test results shown below: Readings for pins with the front power distro wires hooked up to e-load @ 0.5A (12 volts shown) and aux power wires hooked up to power supply & 12V.
| |||
Oct. 13 | Jess + Aashmika | Worked on power distro, work is on branch bts7200-messs
Problem was the load switches couldn’t handle eload in constant current mode and were overload protecting (greater than 500 mA @ 12V for example). Putting eload into constant resistance mode allowed load switch to work consistently. Also added initialization to pin on PCA9539r to set it properly. We might have destroyed U6 and U5 from the overloading with constant current mode as they are constantly enabled now. We also shorted a controller board (3v3 or 12v) and it died. RIP. | Aashmika cries. Couldn’t work on MCI. | ||
Oct 14 | Jess | Power selection, working on branch The “valid” signals work for aux and DCDC, i.e. they’re all 1 except valid_3 when aux is plugged in, and all 1 except valid_2 when dcdc is plugged in. Thermistors didn’t seem to be populated. Power distro, working on branch | |||
Oct 15 | Jess + Aashmika + Ricky | Driver Display: did some setup on raspi, working on getting Precharge: Having problems with precharge and testing to see what could be the issue. Checked fets Q2, Q4 and Q5 all working fine, trying to figure out how the SR latch works. Checked to see if the capacitor is connected to the board and it is connected. Testing the And_out (yellow), reset pin (blue), and SR latch output (purple). Evening shift: Got the driver display app running on the display, steps here: Driver Display setup | |||
Oct 17 | Jess | Tried to talk to new motor controllers. Note: LAWICEL slcan dongle must be used, can’t use peak-can dongle. The old software we were using for the WaveSculptor 20s doesn’t seem to work; it connects but doesn’t seem to read messages and can’t upload/download configs. I suspect the old version of the software isn’t compatible with these controllers. I submitted a request for the newer version of the software through the ‘contact us’ page on their website since the software isn’t listed there. Candumping using karl ding’s old dbc file on github https://github.com/karlding/wavesculptor-22-dbc (with device id changed to 0x400 rather than 0x80 via kvaser DBC editor) gave some output. Next steps are hopefully wait for tritium to give us the new software, otherwise reach out to other solar car teams / post in the solar racing reddit to see if anyone else has a copy of the software. Do we have any contacts at tritium? | |||
Oct 24 | Hewitt | Worked on figuring out why MCP2515 smoke test isn’t working on MCI rev. 4. Wasn’t working on the MCI rev. 5 either, but loopback tests passed on the MSXII charger interface board. We’re also not communicating with the MCP2515 on the MCI rev. 4 (registers read either 0 or 255 before and after trying to change them), but other two boards seem to be working okay in that regard. MCP2515 SPI connections should be identical across all boards, so seems like the rev. 4 one isn’t working. Since it seems to be working, will try to get the charger interface board connected to the WaveSculptor 22 CAN bus tomorrow and start looking at getting readings from it + figuring out whether the MCI is sending all CAN messages at once. | |||
Oct 25 | Selina + Jess | I2C communication not working with ads1015 on pedal board (failing at Also tried to run the smoke test for bts_7200. It’s working on the power distro board when running from the | |||
Oct 25 | Hewitt | Got MSXII charger interface board connected to the WaveSculptor CAN bus. It didn’t seem to be receiving messages when running the MCP2515 smoketest, but was sending messages fine. Flashed MCI FW to the board and verified that it can see CAN messages; it consistently stops calling both velocity and bus message CBs once it gets a bus measurement message. Will look into figuring out the cause of this and look into manually triggering MCI CAN messages tomorrow/later on in the week. Additionally, looks like the WaveSculptor is sending all the update messages at the same time, so we’ll need to look into ways to make this work with the MCP2515. | |||
Oct 26 | Jess | Found another pedal board in the box, so since the ADS1015 is fried on the original one we’re using, Ricky is porting the connectors to the working one. We fried the old one because the potentiometer used was shorted, so now we’re just not connecting the grounds on the pots for the new one. Didn’t get to check it worked fully, but it should work. | |||
Oct 26 | Aashmika + Ricky | Precharge:
AFE: Soldered on the duraclik and microfit connectors, also fixed two ICs that was soldered on the wrong way Pedal Board: Soldered the two potentiometers onto the board for the 3V3 and potentiometer pin but not the ground pin DCDC and Power Distribution: Soldered on the connectors that has easy connections Power Select: Soldered the two thermistors onto the board | |||
Oct 27th | Aashmika + Ricky | Precharge:
| |||
Oct 27 | Hewitt | Worked on figuring out the issue with the MCP2515/WaveSculptor. The MCP2515 driver doesn’t have functionality to set the RTR bit when TXing, which is needed to request a message from the WaveSculptor, so we’ll need to implement this. Generally, the issues seem to stem from the filter configuration on the MCP2515. The current MCI FW uses It seems like the MCP2515 issue where it would only receive a few messages and then stop calling the CBs happens when multiple CAN messages are received at the same time. This is consistent with previous behaviour where we’d sometimes see multiple speed rx’s before seeing a bus measurement rx and eventually failing, since the WaveSculptor seems to send ~4 speed rx’s at around the same time, then a delay, then one of every expected rx at the same time. When testing with the config on It seems like the MCP2515 supports 6 filters total across both rx buffers, so it might make sense to look into adding this functionality to the driver if/when we get the current filter issue resolved. | |||
Oct 28 | Ricky | AFE: fixed the led on the board and checked all components to make sure that they are in the correct direction MCI: I fixed LED4 and Q8 to be in the correct direction now. Found one last U7 left in the MCI Precharge box Battery Module Connector: I have soldered all of the 14pin connectors on the 30 boards | |||
Oct 28 | Hewitt | Continued work on MCI: wrote Looked into requesting status messages by sending a CAN message with the RTR bit set, but I couldn’t get an implementation that didn’t stop working after getting a few messages (similar to earlier MCP2515 issues), so leaving this for now. | |||
Oct 28 | Jess + Selina | Worked on | |||
Oct 29th | Aashmika + Ricky | Precharge Precharge now works! Latching and precharge + discharge sequences were scoped and matched expected function. We also put on the other connectors on MCI for the power train testing. See precharge v5.0 testing document for more information. Pedal Found that the 3V0 pedal regulator is dead on the original pedal board. Replaced it with the reg from the other pedal board, but this regulator seems to only output 1.25V. Note that the other board has a short from 3V3 to GND which is not a priority fix. 1.25V is not enough for the operating conditions of the ADC, so I will look for a replacement. Ricky also crimped the input pots so they can go in the pedal connetor. After replacing the IC, communication works once again! Now with the pots in place, both pots give readings of 3-1486 depending on the turn. Power Distribution + Precharge: Crimped power and ground wires from the PD and put the wires into Precharge to give power Power Distribution + Power Selection: I connected the power supply from the power selection to the power distribution Power Selection + DC-DC Converter: Soldered the power and GND wires from the power DC-DC Converter to power selection | |||
Oct 30 🎃🎃🎃🎃 | Jess + Selina + Ryan (remotely) + help from Aashmika | I saw a black cat walk into the bushes right outside the windows in the atrium. I’m fairly sure I wasn’t tripping but you never know? Felt very seasonal. Box: Discovered running a test on hardware can sometimes give a python error in GDB (unsure?) about importing module usb in Pedal: Hardware values changed for the ADC channels we’re using; we’re now using channel 0 for throttle and channel 1 for brake. Also discovered a bug where if the pedal potentiometer is very large, rollover can occur in the output (INT16_MAX rolling over to negative numbers). Fixed by changing the math (shoutout Selina for carrying that part) to divide by EE_PEDAL_VALUE_DENOMINATOR as the last step. Branch is Power Distribution: Some things weren’t set up properly in smoke_bts7200, so Ryan took care of fixing it up to be usable. We tested with the lights driver board as a load and were very confused by fluctuating readings, but it turned out that board fluctuates in load significantly past a certain brightness. We switched to the E-load and things were consistent. We did some more math (thanks Ryan for showing the desmos linear fit trick) to determine a more accurate conversion from the ADC converted reading to an actual current from the bts 7200s. Put the now working | |||
Oct 30 | Aashmika |
|
| ||
Oct 30 + 31 🎃 | Hewitt | Worked on getting MCI fully functional. There’s something it doesn’t like in cruise control (specifically, when I also need to test these changes on the actual MCI board, I’ve been using the MSXII charger interface to communicate with the motor controller so far but there shouldn’t be much of a change, if any. Overall MCI will hopefully be good to go by EOD tomorrow, since I assume, if worst comes to worst, it isn’t a huge deal if we don’t have cruise control working for the powertrain mockup. | |||
Nov 1 | Hewitt | Continued MCI work. MCP2515 is still kind of wonky, sometimes after flashing it won’t see any messages at all but will work fine after power cycling the board. Either cruise control or precharge FW was causing the issue with it not seeing messages, so I’m leaving both commented out for the powertrain mockup. Switched from the charger interface to MCI boards and the MCP2515 stopped seeing/sending messages on the CAN bus. The CANable is still able to pick up messages on the bus, and when testing the driver it appears that SPI is working OK; additionally, I probed the CAN connections directly on MCI and they’re working as expected. I also ran the MCP2515 smoketest and didn’t see its messages on the bus. The smoketest failed to pick up any messages in loopback mode, which (probably) indicates an internal error to the MCP. One other note: the MCI MCP’s 3 tx buffers fill up after the first 3 tx messages the smoketest tries to send in normal mode. Tested with MCI rev4 instead and it performs as expected (on the Also started working on power selection (branch:
Overall, power selection should be good to go soon-ish | |||
Nov 2 | Jess | CENTRE CONSOLE
HARDWARE TESTING:
FIRMWARE TESTING:
| |||
Nov 3 | Ricky | BMS Carrier: I soldered on some of the components and connectors, before that I took off all of the hanging wires insulated and not insulated MCI Precharge: I replaced the MCP2515 BMS AFEs: I put on the remaining 12 pin connectors on all of the AFEs Center Console: put some tape over the drive and neutral to switch them | |||
Nov 3 | Selina | Power Distribution: I got started on front power distribution validation and was concerned at first about hardware breakpoints when I ran tests, but it wasn’t actually a problem because unit tests running on stm32 do run gdb. The publish_data unit test is currently failing 2/7 tests, which are | |||
Nov 3 | Jess + Ryan | CENTRE CONSOLE
POWER DISTRIBUTION
There’s a terrible segfault going on. The code is haunted by santa claus. Branch: | |||
Nov 3 | Hewitt | Power selection: FW seems to work, implemented the thermistor code from the old power selection with a few changes and got reasonable values. Gonna look over the FW but it should be good to go (haven’t tested whether the CAN messages are getting sent correctly yet). One note is that adding the aux switch seems to have resulted in us not needing to jump start it by powering the controller board through the programmer at first – not 100% sure why this is happening. MCI: tested after Aashmika replaced the MCP2515. It seemed to be working better (seeing messages now, at least, and the rx buffers weren’t filling up) but still wasn’t calling the CBs, even in loopback mode. Aashmika replaced the CAN transceiver later on as well, so I’ll try and test whether that fixed the issues we’re having tomorrow/Thursday. | |||
Nov 3 | Aashmika |
|
| ||
Nov 4 | Selina | Dug around in power distribution
| |||
Nov 4 | Jess | Found that the power distribution code was using so much static memory that there wasn’t any RAM left for the stack, so memory corruption was causing crashing without printing. Discovered that our linker script ( | |||
Nov 6 | Hewitt | MCI: tested with the CAN transceiver replaced and it works now! Somehow it seems like the CAN transceiver was affecting how the MCP2515 worked in loopback mode, which is weird. It’ll definitely make sense to revisit the MCP driver soon-ish to get a better sense of what’s going on. Power distribution: tested when also powering centre console, pedal. Didn’t have a ton of time to look at the setup but it wasn’t acking the requests sent from centre console (testing with aux power on sequence). The rx cb in | |||
Nov 6 | Aashmika | BMS Carrier: After taking off way too many components, I realized that the 12V microfit harness was made incorrectly - I did not make it but found it in the mockup crimped wires box, and used it thinking it would follow our standards of orientation of pin 1 and 2 to gnd vs pwr. It did not, big rip. After figuring this out I put everything we took off back on, and it’s awaiting firmware validation to tell if anything died with the reverse supply polarity. For now on the mockup, it will only be used for the kill switch and the relay implementation Other: I figured out how to depin microfit connectors - use a thin set of tweezers and using one side of the tweezers, insert into the microfit pin on either side (on at a time) from the front of the plug connector. This pushes back the metal tabs and allows the wire to come out. To use the crimp again, take the tweezers and pull back the metal tabs once again. I also made a dual microfit-banana plug harness to use with the power supply and our boards (which from now on are trying to follow the microfit-power connector standard) I organized all the crimps and connectors that came from newark, mouser and digikey. Anything on board is now in the original four bins with dividers in the red shelves, and anything mx150L or High Power is now sitting in a box under the center white table. I finished crimping the MCI contactor connector to have the sense lines on the relay connected | To do :
| ||
Nov 7 | Hewitt | Power distribution: seems like CAN isn’t working on the controller board we were using (labeled “8,” has some string attached to it). Switched it out for the power select controller board and changed front PD ACKs that were initially mocked to actually go through PD and aux/main power on sequences worked as expected, albeit with a really high can ack timeout since my laptop’s slow af. Powered centre console + pedal off PD instead of the power supply and that worked fine as well. Tested power select out by setting it as an expected device in Still need to test power select and power distro at the same time to be sure, but there shouldn’t be any issues between them and centre console during the power on sequences. | |||
Nov 8 | Jess | MISC
CENTRE CONSOLE
MCI
POWER SELECT
BMS
FULL
| |||
Nov 9 | Ricky | BMS Carrier: Soldered on p4 and attached the kill switch to the board Charger interface: Soldered on about half of the components to the board | |||
Nov 10 | Jess + Ricky |
BUG: sometimes computer says it acks but it doesn't actually ack. In this case unplug-replug the CAN dongle, and set it up again, then it acks properly. BMS CARRIER
CENTRE CONSOLE
POWER DISTRIBUTION
Charger Interface: Soldered on the rest of the components Front Power Distribution: Soldered on the 12V power directly to the IC and as well as hot glued the wires to the board to make it less likely for the pads to come off BMS Carrier: There was a short on pins 7 and 8 on the R23 Res Array | |||
Nov 11 | Jess + Aashmika | BMS CARRIER
MISC
CBs:
EVENING SHIFT MISC
MCI
BMS
CENTRE_CONSOLE
POWER_DISTRIBUTION
| |||
Nov 12 | Ricky | AFE: Creating the 14 pin connectors by stripping and crimping wires. Soldered the wires to the battery holders. Cut 60 pieces of heat shrinks. Put on all of the heat sink inserts. Strip all 22G and 18G wires on one end with 3 clicks. | |||
Nov 12 | Jess | MCI
| |||
Nov 14 | Hewitt | MCI: spent a bit of time looking at why it wasn’t working. Eventually traced it down to what looked like HW issues. Aashmika found a short on the CAN transceiver, replaced it, and MCI started working again. For future reference: when starting the MCP2515 in normal mode, we should see roughly the following output on minicom:
If these values are different and we’re having problems with the MCP2515/CAN transceiver it may point to a HW issue. I did notice an issue where sometimes the filters on the MCP2515 let through the wrong message ID, so started writing code to deal with that – shouldn’t be an issue as long as we’re calling the right callback, which I’m 99% sure we are. Not sure if this is new, I remember looking through a bunch of the CAN messages earlier to make sure this wasn’t happening and they all seemed to be working okay. Will look into further over the next few days |