Release 4.9b supports the XIAO nRF54 boards


#1

The latest release 4.9b of the ARM version of uLisp adds support for the Seeed Studio XIAO nRF54 boards:

These are based on the Nordic Semiconductor nRF54L15 and nRF54LM20A ARM Cortex-M33 microcontrollers running at 128 MHz. The XIAO nRF54LM20A is particularly attractive for uLisp because it has twice as much RAM, 512 Kbytes, plus 8 Mbytes of external flash which uLisp uses to save the workspace.

They both have an ultra-low-power design for long battery life, and built-in Li-ion battery management. Their wireless capabilities include: Bluetooth LE 6.0 (include Channel Sounding), NFC, Thread, Zigbee, Matter, Amazon Sidewalk, and Proprietary 2.4 GHz protocols.

They are also available in Sense versions that provide a Six DOF IMU (LSM6DS3TR-C), and a Microphone (MSM261DGT006).

For more information see: XIAO nRF54 Boards.

Get them here: Seeed XIAO nRF54L15 and Seeed XIAO nRF54LM20A.

New tests for analogread and analogwrite

This release of the ARM version of uLisp also updates the routines that provide run-time checking of the functions analogread and analogwrite to use the functions provided by the relevant Arduino core, rather than listing the pins explicitly. This results in more compact code, and will make it easier to add support for new boards to uLisp.

You can use the following function to list the analogread and analogwrite pins for the current board:

; analogtest
; Displays pin numbers available for analogread and analogwrite

(defun analogtest ()
  (let (from)
    (dolist (rw '(("read" #'(lambda (x) (analogread x))) 
                  ("write" #'(lambda (x) (analogwrite x 0)))))
      (format t "~%analog~a: " (first rw))    
      (dotimes (x 128)
        (let ((test (eq (ignore-errors (funcall (second rw) x)) NOTHING)))
          (cond
           ((and (not test) (null from)) (setq from x))
           ((and test from)
            (if (= from (1- x)) (format t "~a " from)
              (format t "~a-~a " from (1- x)))
            (setq from nil))))))))

For example:

> (analogtest)

analogread: 0 2-3 6 9-10 15-20 22-23 
analogwrite: 0-35 


Implementation of analogread and analogwrite error checking