[Snek] [keith-packard/snek] aa484e: ports/narrow-1284: Add support for Narrow 1284 board
Keith Packard
noreply at github.com
Fri Feb 5 00:15:42 PST 2021
Branch: refs/heads/main
Home: https://github.com/keith-packard/snek
Commit: aa484e29eca2cb7561d87999dad8e2fa4e3fcf2d
https://github.com/keith-packard/snek/commit/aa484e29eca2cb7561d87999dad8e2fa4e3fcf2d
Author: Keith Packard <keithp at keithp.com>
Date: 2020-11-10 (Tue, 10 Nov 2020)
Changed paths:
M chips/atmega/snek-atmega-serial.c
A ports/narrow-1284/Makefile
A ports/narrow-1284/machine/ieeefp.h
A ports/narrow-1284/snek-narrow-1284-install.1
A ports/narrow-1284/snek-narrow-1284-install.in
A ports/narrow-1284/snek-narrow-1284-math.builtin
A ports/narrow-1284/snek-narrow-1284.builtin
A ports/narrow-1284/snek-narrow-1284.c
A ports/narrow-1284/snek-narrow-1284.h
M snek-install.defs
Log Message:
-----------
ports/narrow-1284: Add support for Narrow 1284 board
This board has an ATmega 1284 processor and is being sold through
Crowd Supply.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 358ef187a10c932b8843d46aad51a65d9f91b273
https://github.com/keith-packard/snek/commit/358ef187a10c932b8843d46aad51a65d9f91b273
Author: Keith Packard <keithp at keithp.com>
Date: 2020-12-07 (Mon, 07 Dec 2020)
Changed paths:
A chips/atmega/machine/ieeefp.h
R ports/mega/machine/ieeefp.h
R ports/narrow-1284/machine/ieeefp.h
Log Message:
-----------
Move atmega ieeefp.h file to chips/atmega/machine
Instead of having more than one of these.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: bacc7a47982a227f708fac61f2431ac45ffdd26f
https://github.com/keith-packard/snek/commit/bacc7a47982a227f708fac61f2431ac45ffdd26f
Author: Keith Packard <keithp at keithp.com>
Date: 2020-12-07 (Mon, 07 Dec 2020)
Changed paths:
M chips/atmega/snek-328p.builtin
M chips/atmega/snek-atmega-eeprom.c
M chips/atmega/snek-atmega-serial.c
M ports/mega/snek-mega.builtin
M ports/narrow-1284/snek-narrow-1284.builtin
M snekde/snekde.py
Log Message:
-----------
chips/atmega: Make EEPROM size target-specific. Add sync eeprom
328p has 1024 bytes of eeprom, 1284 and 2560 have 4096 bytes. Devices
missing xon/xoff support need synchronous put support where the target
sends a CR every 16 bytes and the host waits for that. This avoids
overrunning the serial input buffer.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 29bdeb9bed5aa32265a3efab1f1db7064e90c1e4
https://github.com/keith-packard/snek/commit/29bdeb9bed5aa32265a3efab1f1db7064e90c1e4
Author: Keith Packard <keithp at keithp.com>
Date: 2020-12-07 (Mon, 07 Dec 2020)
Changed paths:
M chips/atmega/snek-328p.c
M chips/qemu/snek-qemu.c
M chips/samd21/snek-altos.c
M ports/esp32/main/snek-esp32.c
M ports/hifive1revb/snek-metal-builtin.c
M ports/mega/snek-mega.c
M ports/narrow-1284/Makefile
M ports/narrow-1284/snek-narrow-1284.c
Log Message:
-----------
Use all available bits for random.randrange
Don't truncate to snek_soffset_t and allow random.randrange to work up
to the largest float
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 9c83d0966c5795133563b93aea746dd47591bb0a
https://github.com/keith-packard/snek/commit/9c83d0966c5795133563b93aea746dd47591bb0a
Author: Keith Packard <keithp at keithp.com>
Date: 2021-01-30 (Sat, 30 Jan 2021)
Changed paths:
M snek.svg
Log Message:
-----------
Remove stray <circle> in snek.svg
This doesn't appear to contribute to the rendered image and elicits a
warning from asciidoctor.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: db90df7a563d44f68703066deecb26badf6e06fb
https://github.com/keith-packard/snek/commit/db90df7a563d44f68703066deecb26badf6e06fb
Author: Keith Packard <keithp at keithp.com>
Date: 2021-01-30 (Sat, 30 Jan 2021)
Changed paths:
M test/Makefile
A test/pass-random.py
Log Message:
-----------
test: Add pass-random.py
This tests to see if the 'randrange' function returns values outside
of the specified range.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 9955a82411a71e1b885df2f0886e5c7168273b59
https://github.com/keith-packard/snek/commit/9955a82411a71e1b885df2f0886e5c7168273b59
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
M snek-exec.c
M snek-gram.ll
M snek-list.c
M snek-parse.c
M snek-string.c
M snek.defs
Log Message:
-----------
Add SNEK_NO_SLICE build option
List and string slices take a bunch of code. Make them optional so
that smaller platforms can save that space.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 67abfbd8c5f620b5ed35f07f16aeb80f66eee598
https://github.com/keith-packard/snek/commit/67abfbd8c5f620b5ed35f07f16aeb80f66eee598
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
M chips/atmega/snek-328p.c
M chips/atmega/snek-atmega-time.c
Log Message:
-----------
chips/atmega: Add 'tone' support on D5
This reprograms timer0 to generate tones on pin D5. To do that, the
main clock now uses timer2.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 6f265a2b33c9aee0a7b15a5d6982e4fd16799ea9
https://github.com/keith-packard/snek/commit/6f265a2b33c9aee0a7b15a5d6982e4fd16799ea9
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
M snek-exec.c
M snek-gram.ll
M snek-lex.c
M snek-list.c
M snek-parse.c
M snek-poly.c
M snek-print.c
M snek-string.c
M snek.defs
M snek.h
Log Message:
-----------
Add SNEK_NO_DICT build option
This option removes dictionaries from the language, saving
considerable space in ROM.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: e35ac1625868575a6a5636f1d3b2e39839d184e6
https://github.com/keith-packard/snek/commit/e35ac1625868575a6a5636f1d3b2e39839d184e6
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
M ports/uno/Makefile
M ports/uno/snek-uno-install.in
Log Message:
-----------
ports/uno: Switch to 115200 baud, require sync eeprom loading
Instead of relying on flow control when loading programs, use the
synchronous loading function which sends \r after each chunk that the
host can use to avoid overflowing the serial buffer.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 3040eede3956da4c933f0e8a32d1a71a82d747c8
https://github.com/keith-packard/snek/commit/3040eede3956da4c933f0e8a32d1a71a82d747c8
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
A chips/atmega/snek-atmega-i2c.c
A snek-i2c.h
Log Message:
-----------
chips/atmega: Add i2c driver
This adds a basic i2c interface. The two functions exposed are:
void snek_i2c_put(uint8_t addr, uint8_t reg, uint8_t val);
uint8_t snek_i2c_get(uint8_t addr, uint8_t reg);
These functions read/write individual byte registers in the device
with the specified address The address is left-justified with the LSB
read-bit set to zero.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 0ae9d79dad44eac795d11b84eb7e4aceb8c5416f
https://github.com/keith-packard/snek/commit/0ae9d79dad44eac795d11b84eb7e4aceb8c5416f
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
A snek-bmp280.c
A snek-lis3dh.c
Log Message:
-----------
Add BMP280 and LIS3DH drivers
These two i2c devices are found in the Grove Beginner Kit.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 846d9703e32d9bdad323cd34127e359dcfb11753
https://github.com/keith-packard/snek/commit/846d9703e32d9bdad323cd34127e359dcfb11753
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
A ports/grove/.gitignore
A ports/grove/Makefile
A ports/grove/snek-grove-install.1
A ports/grove/snek-grove-install.in
A ports/grove/snek-grove.builtin
M snek-install.defs
Log Message:
-----------
snek/grove: Add port for Seeed's Grove Beginner Kit
This supports many of the devices supplied in this kit, including:
1. LED
2. Buzzer (with tone function)
3. Light sensor
4. Sound sensor
5. Button
6. Rotary Potentiometer
7. Air Pressure
8. 3-Axis Acceleration
Still to add:
1. OLED display
2. Temperature and Humidity
Of course, the ROM is full at this point, so adding these presents a
significant challenge.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 188bfd775152f55a49d376a863951f8c6cb90779
https://github.com/keith-packard/snek/commit/188bfd775152f55a49d376a863951f8c6cb90779
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
M chips/atmega/snek-atmega-eeprom.c
M chips/avr/snek-avr-eeprom.c
M chips/samd21/snek-eeprom.c
M ports/mega/snek-mega.builtin
M snekde/snekde.py
Log Message:
-----------
chips, snekde: Update eeprom writing code to work synchronously
The synchronous eeprom writing code works by sending a carriage-return
after each 16 bytes received. This makes the process more reliable,
even when the underlying serial link has no flow control.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 94814cdb9c8ccf546e682e23f8ddb2919518f3be
https://github.com/keith-packard/snek/commit/94814cdb9c8ccf546e682e23f8ddb2919518f3be
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-02 (Tue, 02 Feb 2021)
Changed paths:
M ports/mega/Makefile
A snek-i2c.builtin
A snek-i2c.c
Log Message:
-----------
ports/mega: Add bare i2c API to mega port
Get/put register values to any i2c device.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: fbd90a10b8719c2ab7476c3d4429f0a8ea6a6449
https://github.com/keith-packard/snek/commit/fbd90a10b8719c2ab7476c3d4429f0a8ea6a6449
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-03 (Wed, 03 Feb 2021)
Changed paths:
M ports/duemilanove/.gitignore
M ports/duemilanove/Makefile
R ports/duemilanove/snek-duemilanove-install.1
A ports/duemilanove/snek-duemilanove-install.1.in
R ports/mega/Arduino-usbserial-atmega16u2-Mega2560-Rev3.hex
R ports/uno/Arduino-usbserial-atmega16u2-Uno-Rev3.hex
M ports/uno/Makefile
R ports/uno/snek-uno-install.1
R ports/uno/snek-uno-install.in
Log Message:
-----------
ports/uno: Use duemilanove files to build this target
Uno is identical to duemilanove except for the name and the default
tty port used when installing.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 0be07157912ce8d0e86c801406c6cbfa580ea76e
https://github.com/keith-packard/snek/commit/0be07157912ce8d0e86c801406c6cbfa580ea76e
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-03 (Wed, 03 Feb 2021)
Changed paths:
M chips/atmega/snek-atmega-i2c.c
Log Message:
-----------
chips/atmega: Support atmega with i2c on portd
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 950e734eaf6d45b4bf0c43fce19736a39b5c10d4
https://github.com/keith-packard/snek/commit/950e734eaf6d45b4bf0c43fce19736a39b5c10d4
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-03 (Wed, 03 Feb 2021)
Changed paths:
M ports/posix/snek-main.c
M snek-io.c
M snek-parse.c
Log Message:
-----------
Reset parser on interrupt
Check for snek_abort after snek_lex returns, returning
parse_return_error if true. This makes sure the parser is completely
reset on interrupt, providing a reliable way to get back to a clean
state.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 12b6a2a9642533cf2c9a8f439197fc9db65dc1b4
https://github.com/keith-packard/snek/commit/12b6a2a9642533cf2c9a8f439197fc9db65dc1b4
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-03 (Wed, 03 Feb 2021)
Changed paths:
M chips/atmega/snek-atmega-eeprom.c
M chips/atmega/snek-atmega-serial.c
M chips/avr/snek-avr-eeprom.c
M chips/samd21/snek-eeprom.c
Log Message:
-----------
Abandon eeprom reading after interrupt or error
Stop reading from eeprom when we encounter an error or the user
interrupts execution. This makes sure a ^C can get back to a known
state.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 079fbc1044dd504687b334143695959908e93ef9
https://github.com/keith-packard/snek/commit/079fbc1044dd504687b334143695959908e93ef9
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-03 (Wed, 03 Feb 2021)
Changed paths:
M ports/mega/Makefile
M ports/mega/snek-mega-install.1
M ports/mega/snek-mega-install.in
Log Message:
-----------
ports/mega: Remove atmega16u2 bits from snek-mega-install
Now that loading is synchronous on this device, leave the default boot
loader in place and use that.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 4304a1fad6e1343242df06bae15ab26aa1f52b9c
https://github.com/keith-packard/snek/commit/4304a1fad6e1343242df06bae15ab26aa1f52b9c
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-03 (Wed, 03 Feb 2021)
Changed paths:
M ports/mega/snek-mega.c
Log Message:
-----------
ports/mega: Switch clock to timer 2
This follows the other atmega users which want to allow timer 2 to be
used for the tone operation.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 2138e2562837cd1cef9ef6dd4c32c204c8ca05eb
https://github.com/keith-packard/snek/commit/2138e2562837cd1cef9ef6dd4c32c204c8ca05eb
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-03 (Wed, 03 Feb 2021)
Changed paths:
M snekde/snekde.py
Log Message:
-----------
snekde: Repaint code window after loading file
Make sure the user sees the updated bits.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 598066b35811ac6a5c6198cd9b1170e053febcc7
https://github.com/keith-packard/snek/commit/598066b35811ac6a5c6198cd9b1170e053febcc7
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-04 (Thu, 04 Feb 2021)
Changed paths:
A snek-draw.builtin
A snek-ssd1315.c
Log Message:
-----------
Add SSD1315 driver (128x64 OLED screen via I2C)
This is the screen that comes with the Grove Beginner Kit. To work
with the 328p's memory limitations, this driver creates a half-scale
bitmap and then expands it.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 2f91314d05bff6da1c5805b847450a7d17dbc27b
https://github.com/keith-packard/snek/commit/2f91314d05bff6da1c5805b847450a7d17dbc27b
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-05 (Fri, 05 Feb 2021)
Changed paths:
M chips/atmega/snek-328p.builtin
M chips/atmega/snek-atmega.h
M ports/mega/snek-mega.builtin
Log Message:
-----------
chips/atmega: Increase parse stack size to 128 by shrinking heap
The tiny 64 element parse stack could be overflowed by nesting parens
twice. The heap is shrunk to 768 bytes so that the stack will fit.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 7febea141da21fb3ad63d0fe9de07d076256ba2f
https://github.com/keith-packard/snek/commit/7febea141da21fb3ad63d0fe9de07d076256ba2f
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-05 (Fri, 05 Feb 2021)
Changed paths:
M chips/atmega/snek-atmega-i2c.c
M snek-i2c.h
Log Message:
-----------
Expose low-level i2c interface
This lets drivers use a lower-level interface than register get/put.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 699616ee76456dbe1642e40abdb49d2c819171fd
https://github.com/keith-packard/snek/commit/699616ee76456dbe1642e40abdb49d2c819171fd
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-05 (Fri, 05 Feb 2021)
Changed paths:
M snek-builtin.py
Log Message:
-----------
Allow '#if defined' in .builtin files
All that was necessary was to pass any '#endif' lines through that
didn't match a #ifdef
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 9d86ef28bfbb3f8b2380a4fcac43102021a2b4eb
https://github.com/keith-packard/snek/commit/9d86ef28bfbb3f8b2380a4fcac43102021a2b4eb
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-05 (Fri, 05 Feb 2021)
Changed paths:
M snek-gram.ll
Log Message:
-----------
Fix array index parsing when SNEK_SLICE is not set
The replacement code wasn't pushing the slice indicator to the value
stack, which broke parsing. Fix by removing the code which checks for
that entry.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 8dc156198707457b6520a9b4ee5d4d29700489d5
https://github.com/keith-packard/snek/commit/8dc156198707457b6520a9b4ee5d4d29700489d5
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-05 (Fri, 05 Feb 2021)
Changed paths:
M snek-input.c
Log Message:
-----------
Allow portions of snek-input.c to be used in isolation
Just avoid compiler warnings about the unused functions
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 5c64fa8af4b14a8a85e9440eb631defb43ded3d1
https://github.com/keith-packard/snek/commit/5c64fa8af4b14a8a85e9440eb631defb43ded3d1
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-05 (Fri, 05 Feb 2021)
Changed paths:
M ports/grove/Makefile
M ports/grove/snek-grove.builtin
Log Message:
-----------
ports/grove: Add OLED, remove baro
The OLED seems like more fun than the baro sensor, and we don't have
space for both drivers.
Signed-off-by: Keith Packard <keithp at keithp.com>
Commit: 0db0eba29c4a7edc454e5d07025c7e4ddf900cd9
https://github.com/keith-packard/snek/commit/0db0eba29c4a7edc454e5d07025c7e4ddf900cd9
Author: Keith Packard <keithp at keithp.com>
Date: 2021-02-05 (Fri, 05 Feb 2021)
Changed paths:
M ports/duemilanove/.gitignore
M ports/duemilanove/Makefile
M ports/uno/.gitignore
Log Message:
-----------
ports/duemilanove: Clean generated man page
Now that the man page is generated to share with the uno port, it
needs to be cleaned.
Signed-off-by: Keith Packard <keithp at keithp.com>
Compare: https://github.com/keith-packard/snek/compare/87cb807238cb...0db0eba29c4a
More information about the Snek
mailing list