Bug Squashing, gdbdiff & MicroPython - Coding Raspberry Pi Pico Emulator

preview_player
Показать описание
Gotta Catch 'Em All! We're going to eliminate some tricky bugs that I found while preparing for the next class of the Pi Pico Deep Dive course. Then, we'll try to get MicroPython to run in the emulator.

In this live-coding series we're implementing an emulator for the RP2040 chip, which powers the new Raspberry Pi Pico. Every week we implement a new feature together, diving into the datasheet and thickening our Cortex M0+ implementation.

Get emails with the links to the future stream:

0:00 Hello! 👋
2:06 Reviewing the open bugs + Valerio's PR
3:25 SP/R13 bits should always be zero #17
45:23 POP and ExceptionReturn don't play nicely together #21
1:02:10 User generated interrupts (IRQ ≥ 26) keep firing forever #22
1:19:17 printf() incorrectly formats numbers (Arduino Mbed Core) #24
1:25:00 gdbdiff bug squashing! 🐛🔫
1:32:11 ADD reg shouldn't update flags
1:50:08 ADCS adding 0+0 with carry shouldn't set overflow
2:03:15 CMP (immediate) incorrectly setting carry
2:27:35 CMP (register) incorrectly setting carry
2:37:30 The printf() issue: LSRS with shift ≥ 32
2:57:52 MicroPython?
3:18:56 Wrapping up + releasing rp2040js v0.3.7!
Рекомендации по теме
Комментарии
Автор

clearPend = ExceptionIN(INTNUM) || InterruptDeassertion;
setPend = InterruptAssertion || WriteToRegField(ISPR, INTNUM);

Note that for hardware IRQs the InterruptAssertion is always set until the hardware interrupt source is acknowledged via a write to the hardware specific interrupt register (basically level sensitive interrupts)... thus if the ISR doesn't do this you get another IRQ immediately on return from the ISR. For the write to ISPR case, the setPend only happens once.

kilograham
Автор

CMP immediate is still wrong even if it passed test. carry = X >= Y, where Y = NOT(imm8)

chegewaras
join shbcf.ru