{"id":20446283,"url":"https://github.com/rust-embedded/msp430","last_synced_at":"2025-06-14T16:06:09.718Z","repository":{"id":33421423,"uuid":"146803743","full_name":"rust-embedded/msp430","owner":"rust-embedded","description":"Low level access to MSP430 microcontrollers","archived":false,"fork":false,"pushed_at":"2022-12-05T03:25:22.000Z","size":178,"stargazers_count":39,"open_issues_count":3,"forks_count":6,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-06-05T11:02:25.220Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rust-embedded.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null}},"created_at":"2018-08-30T20:34:48.000Z","updated_at":"2025-05-12T09:47:57.000Z","dependencies_parsed_at":"2023-01-15T00:51:10.686Z","dependency_job_id":null,"html_url":"https://github.com/rust-embedded/msp430","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/rust-embedded/msp430","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-embedded%2Fmsp430","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-embedded%2Fmsp430/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-embedded%2Fmsp430/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-embedded%2Fmsp430/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rust-embedded","download_url":"https://codeload.github.com/rust-embedded/msp430/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-embedded%2Fmsp430/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259843330,"owners_count":22920312,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-15T10:18:51.558Z","updated_at":"2025-06-14T16:06:09.693Z","avatar_url":"https://github.com/rust-embedded.png","language":"Rust","readme":"[![crates.io](https://img.shields.io/crates/d/msp430.svg)](https://crates.io/crates/msp430)\n[![crates.io](https://img.shields.io/crates/v/msp430.svg)](https://crates.io/crates/msp430)\n\n# `msp430`\n\n\u003e Low level access to MSP430 microcontrollers\n\nThis crate is based on [cortex-m](https://docs.rs/cortex-m) crate by Jorge Aparicio (@japaric).\n\n**This crate requires a nightly rust due to the use of the new `asm!` (`0.3.0`\nand above), `llvm_asm!` (`0.2.2`) or old `asm!` (`0.2.1` and below) macros.**\nThe below table contains compilers which are known to work:\n\n|`msp430` version|`rustc` compiler    |\n|----------------|--------------------|\n|`0.3.0`         |`nightly-2022-01-24`|\n|`0.2.2`         |`nightly-2020-04-22`|\n|`0.2.1`         |`nightly-2020-01-04`|\n\n## Features\n\nThe `critical-section-single-core` feature provides a [critical section](https://github.com/rust-embedded/critical-section)\nimplementation based upon disabling interrupts.\n\nCritical sections by disabling interrupts are a valuable way to access I/O and\nshared data safely in msp430. However, rustc/LLVM does not always optimize\ncritical sections well in terms of space. For example, sometimes rustc/LLVM\nwill create two copies of interrupt enable assembly code when exiting a\ncritical section that contains a branch- one copy each for\nbranch-taken/branch-not-taken.\n\nThis crate provides three features for giving hints to rustc/LLVM for how to\noptimize critical sections for size. Both `critical_section::with` and\nthe `interrupt::free` critical sections are supported, with and without the\n`critical-section` feature above:\n\n* `outline-cs-acq`: Hint to rustc/LLVM that each critical section entry should\n   be a call to a single copy of an `acquire` function (disable interrupts).\n* `outline-cs-rel`: Hint to rustc/LLVM that each critical section exit should\n   be a call to a single copy of a `release` function (enable interrupts if not\n   in a nested critical section).\n* `outline-cs`: Convenience feature for enabling both of the above at the same\n   time.\n\nIf saving space is a concern in your application, you should experiment with\nwhich features provide the best size savings and balance this against the\nexecution overhead of the extra function calls due to outlining. The execution\noverhead of enabling each hint is ~5 + 2 clock cycles for each\ncritical section- at least a `CALL` and `RET` instruction.\n\n## [Documentation](https://docs.rs/crate/msp430)\n\n## License\n\nLicensed under either of\n\n- Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or\n  http://www.apache.org/licenses/LICENSE-2.0)\n- MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)\n\nat your option.\n\n### Contribution\n\nUnless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the\nwork by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any\nadditional terms or conditions.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frust-embedded%2Fmsp430","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frust-embedded%2Fmsp430","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frust-embedded%2Fmsp430/lists"}