Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -439,5 +439,6 @@ The `atomvm` properties list in the Mix project file (`mix.exs`) may contain the
| Key | Type | Default | Value |
|-----|------|----------|-------|
| `app_start` | Address in hexademical format | 0x10180000 | The flash address to place the application |
| `family_id` | atom or string | `universal` | The flavor of uf2 to create; `rp2040`, `rp2350_riscv`, `rp2350_arm_s`, `rp2350_arm_ns`, `data`, `absolute`, or `universal` |

Properties in the `mix.exs` file may be over-ridden on the command line using long-style flags (prefixed by `--`) by the same name as the properties key. For example, you can use the `--app_start` option to specify or override the `app_start` property in the above table.
41 changes: 34 additions & 7 deletions lib/mix/tasks/uf2create.ex
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ defmodule Mix.Tasks.Atomvm.Uf2create do
Keyword.get(
avm_config,
:family_id,
Map.get(options, :family_id, System.get_env("ATOMVM_PICO_UF2_FAMILY", "rp2040"))
Map.get(options, :family_id, System.get_env("ATOMVM_PICO_UF2_FAMILY", :universal))
)
)

Expand Down Expand Up @@ -131,14 +131,41 @@ defmodule Mix.Tasks.Atomvm.Uf2create do
:rp2040 ->
:rp2040

"rp2035" ->
:data
"rp2350_riscv" ->
:rp2350_riscv

":rp2035" ->
:data
":rp2350_riscv" ->
:rp2350_riscv

:rp2035 ->
:data
:rp2350_riscv ->
:rp2350_riscv

"rp2350_arm_s" ->
:rp2350_arm_s

":rp2350_arm_s" ->
:rp2350_arm_s

:rp2350_arm_s ->
:rp2350_arm_s

"rp2350_arm_ns" ->
:rp2350_arm_ns

":rp2350_arm_ns" ->
:rp2350_arm_ns

:rp2350_arm_ns ->
:rp2350_arm_ns

"absolute" ->
:absolute

":absolute" ->
:absolute

:universal ->
:absolute

"data" ->
:data
Expand Down