From 2e1c1f932070cf7f04dec5e364391cdd1abd906f Mon Sep 17 00:00:00 2001 From: Your Name Date: Wed, 15 Jul 2020 02:47:08 -0400 Subject: [PATCH] ugh --- .../code/mplab/tests4_timer_6000hz.X/Makefile | 113 +++++ .../code/mplab/tests4_timer_6000hz.X/main.c | 76 ++++ .../nbproject/Makefile-default.mk | 158 +++++++ .../nbproject/Makefile-genesis.properties | 10 + .../nbproject/Makefile-impl.mk | 69 +++ .../nbproject/Makefile-local-default.mk | 36 ++ .../nbproject/Makefile-variables.mk | 13 + .../nbproject/Package-default.bash | 73 ++++ .../nbproject/configurations.xml | 160 +++++++ .../nbproject/private/configurations.xml | 25 ++ .../nbproject/private/private.xml | 9 + .../nbproject/project.xml | 32 ++ .../code/mplab/tests5_timer_6000hz.X/Makefile | 113 +++++ .../build/default/production/main.o | Bin 0 -> 3172 bytes .../build/default/production/main.o.d | 55 +++ .../dist/default/production/memoryfile.xml | 17 + .../tests5_timer_6000hz.X.production.elf | Bin 0 -> 6012 bytes .../tests5_timer_6000hz.X.production.hex | 10 + .../tests5_timer_6000hz.X.production.map | 400 ++++++++++++++++++ .../code/mplab/tests5_timer_6000hz.X/main.c | 83 ++++ .../nbproject/Makefile-default.mk | 158 +++++++ .../nbproject/Makefile-genesis.properties | 10 + .../nbproject/Makefile-impl.mk | 69 +++ .../nbproject/Makefile-local-default.mk | 36 ++ .../nbproject/Makefile-variables.mk | 13 + .../nbproject/Package-default.bash | 73 ++++ .../nbproject/configurations.xml | 160 +++++++ .../nbproject/private/configurations.xml | 25 ++ .../nbproject/private/private.xml | 7 + .../nbproject/project.xml | 33 ++ .../code/mplab/tests6_timer_6000hz.X/Makefile | 113 +++++ .../build/default/production/main.o | Bin 0 -> 3280 bytes .../build/default/production/main.o.d | 55 +++ .../dist/default/production/memoryfile.xml | 17 + .../tests6_timer_6000hz.X.production.elf | Bin 0 -> 6060 bytes .../tests6_timer_6000hz.X.production.hex | 11 + .../tests6_timer_6000hz.X.production.map | 400 ++++++++++++++++++ .../code/mplab/tests6_timer_6000hz.X/main.c | 135 ++++++ .../nbproject/Makefile-default.mk | 158 +++++++ .../nbproject/Makefile-genesis.properties | 10 + .../nbproject/Makefile-impl.mk | 69 +++ .../nbproject/Makefile-local-default.mk | 36 ++ .../nbproject/Makefile-variables.mk | 13 + .../nbproject/Package-default.bash | 73 ++++ .../nbproject/configurations.xml | 160 +++++++ .../nbproject/private/configurations.xml | 25 ++ .../nbproject/private/private.xml | 9 + .../nbproject/project.xml | 34 ++ .../mplab/tests7_timer_6000hz_FAIL.X/Makefile | 113 +++++ .../build/default/production/main.o | Bin 0 -> 2808 bytes .../build/default/production/main.o.d | 55 +++ .../dist/default/production/memoryfile.xml | 17 + .../tests7_timer_6000hz.X.production.elf | Bin 0 -> 5828 bytes .../tests7_timer_6000hz.X.production.hex | 9 + .../tests7_timer_6000hz.X.production.map | 395 +++++++++++++++++ .../mplab/tests7_timer_6000hz_FAIL.X/main.c | 150 +++++++ .../nbproject/Makefile-default.mk | 158 +++++++ .../nbproject/Makefile-genesis.properties | 10 + .../nbproject/Makefile-impl.mk | 69 +++ .../nbproject/Makefile-local-default.mk | 36 ++ .../nbproject/Makefile-variables.mk | 13 + .../nbproject/Package-default.bash | 73 ++++ .../nbproject/configurations.xml | 160 +++++++ .../nbproject/private/configurations.xml | 25 ++ .../nbproject/private/private.xml | 9 + .../nbproject/project.xml | 35 ++ Attiny_Solar_Energy_Harvest/docs/38.tex | 13 + 67 files changed, 4694 insertions(+) create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/Makefile create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/main.c create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-default.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-genesis.properties create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-impl.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-local-default.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-variables.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Package-default.bash create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/configurations.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/private/configurations.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/private/private.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/project.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/Makefile create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/build/default/production/main.o create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/build/default/production/main.o.d create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/dist/default/production/memoryfile.xml create mode 100755 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/dist/default/production/tests5_timer_6000hz.X.production.elf create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/dist/default/production/tests5_timer_6000hz.X.production.hex create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/dist/default/production/tests5_timer_6000hz.X.production.map create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/main.c create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-default.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-genesis.properties create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-impl.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-local-default.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-variables.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Package-default.bash create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/configurations.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/private/configurations.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/private/private.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/project.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/Makefile create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/build/default/production/main.o create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/build/default/production/main.o.d create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/memoryfile.xml create mode 100755 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/tests6_timer_6000hz.X.production.elf create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/tests6_timer_6000hz.X.production.hex create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/tests6_timer_6000hz.X.production.map create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/main.c create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-default.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-genesis.properties create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-impl.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-local-default.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-variables.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Package-default.bash create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/configurations.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/private/configurations.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/private/private.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/project.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/Makefile create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/build/default/production/main.o create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/build/default/production/main.o.d create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/memoryfile.xml create mode 100755 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/tests7_timer_6000hz.X.production.elf create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/tests7_timer_6000hz.X.production.hex create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/tests7_timer_6000hz.X.production.map create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/main.c create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-default.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-genesis.properties create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-impl.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-local-default.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-variables.mk create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Package-default.bash create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/configurations.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/private/configurations.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/private/private.xml create mode 100644 Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/project.xml diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/Makefile b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/Makefile new file mode 100644 index 0000000..fca8e2c --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/Makefile @@ -0,0 +1,113 @@ +# +# There exist several targets which are by default empty and which can be +# used for execution of your targets. These targets are usually executed +# before and after some main targets. They are: +# +# .build-pre: called before 'build' target +# .build-post: called after 'build' target +# .clean-pre: called before 'clean' target +# .clean-post: called after 'clean' target +# .clobber-pre: called before 'clobber' target +# .clobber-post: called after 'clobber' target +# .all-pre: called before 'all' target +# .all-post: called after 'all' target +# .help-pre: called before 'help' target +# .help-post: called after 'help' target +# +# Targets beginning with '.' are not intended to be called on their own. +# +# Main targets can be executed directly, and they are: +# +# build build a specific configuration +# clean remove built files from a configuration +# clobber remove all built files +# all build all configurations +# help print help mesage +# +# Targets .build-impl, .clean-impl, .clobber-impl, .all-impl, and +# .help-impl are implemented in nbproject/makefile-impl.mk. +# +# Available make variables: +# +# CND_BASEDIR base directory for relative paths +# CND_DISTDIR default top distribution directory (build artifacts) +# CND_BUILDDIR default top build directory (object files, ...) +# CONF name of current configuration +# CND_ARTIFACT_DIR_${CONF} directory of build artifact (current configuration) +# CND_ARTIFACT_NAME_${CONF} name of build artifact (current configuration) +# CND_ARTIFACT_PATH_${CONF} path to build artifact (current configuration) +# CND_PACKAGE_DIR_${CONF} directory of package (current configuration) +# CND_PACKAGE_NAME_${CONF} name of package (current configuration) +# CND_PACKAGE_PATH_${CONF} path to package (current configuration) +# +# NOCDDL + + +# Environment +MKDIR=mkdir +CP=cp +CCADMIN=CCadmin +RANLIB=ranlib + + +# build +build: .build-post + +.build-pre: +# Add your pre 'build' code here... + +.build-post: .build-impl +# Add your post 'build' code here... + + +# clean +clean: .clean-post + +.clean-pre: +# Add your pre 'clean' code here... +# WARNING: the IDE does not call this target since it takes a long time to +# simply run make. Instead, the IDE removes the configuration directories +# under build and dist directly without calling make. +# This target is left here so people can do a clean when running a clean +# outside the IDE. + +.clean-post: .clean-impl +# Add your post 'clean' code here... + + +# clobber +clobber: .clobber-post + +.clobber-pre: +# Add your pre 'clobber' code here... + +.clobber-post: .clobber-impl +# Add your post 'clobber' code here... + + +# all +all: .all-post + +.all-pre: +# Add your pre 'all' code here... + +.all-post: .all-impl +# Add your post 'all' code here... + + +# help +help: .help-post + +.help-pre: +# Add your pre 'help' code here... + +.help-post: .help-impl +# Add your post 'help' code here... + + + +# include project implementation makefile +include nbproject/Makefile-impl.mk + +# include project make variables +include nbproject/Makefile-variables.mk diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/main.c b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/main.c new file mode 100644 index 0000000..2c084d6 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/main.c @@ -0,0 +1,76 @@ +#include +#include +#include + +#include +#include +#include +#include + +//reference: https://www.avrfreaks.net/forum/sample-project-attiny10 +//another ref: https://blog.podkalicki.com/attiny13-blinky-with-timer-compa/ +// + +// Wake up by WDT interrupt. +// Don't need to do anything here but (auto-) clearing the interrupt flag. +EMPTY_INTERRUPT(WDT_vect); + +/* + Delay in powerdown mode. Wake up by watchdog interrupt. + */ +void delay_power_down_wdt(uint8_t wdto) +{ + wdt_reset(); + wdt_enable(wdto); + WDTCSR |= (1<.dep.inc +# @if [ -n "${MAKE_VERSION}" ]; then \ +# echo "DEPFILES=\$$(wildcard \$$(addsuffix .d, \$${OBJECTFILES}))" >>.dep.inc; \ +# echo "ifneq (\$${DEPFILES},)" >>.dep.inc; \ +# echo "include \$${DEPFILES}" >>.dep.inc; \ +# echo "endif" >>.dep.inc; \ +# else \ +# echo ".KEEP_STATE:" >>.dep.inc; \ +# echo ".KEEP_STATE_FILE:.make.state.\$${CONF}" >>.dep.inc; \ +# fi diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-local-default.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-local-default.mk new file mode 100644 index 0000000..62e3bb2 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-local-default.mk @@ -0,0 +1,36 @@ +# +# Generated Makefile - do not edit! +# +# +# This file contains information about the location of compilers and other tools. +# If you commmit this file into your revision control server, you will be able to +# to checkout the project and build it from the command line with make. However, +# if more than one person works on the same project, then this file might show +# conflicts since different users are bound to have compilers in different places. +# In that case you might choose to not commit this file and let MPLAB X recreate this file +# for each user. The disadvantage of not commiting this file is that you must run MPLAB X at +# least once so the file gets created and the project can be built. Finally, you can also +# avoid using this file at all if you are only building from the command line with make. +# You can invoke make with the values of the macros: +# $ makeMP_CC="/opt/microchip/mplabc30/v3.30c/bin/pic30-gcc" ... +# +PATH_TO_IDE_BIN=/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/ +# Adding MPLAB X bin directory to path. +PATH:=/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/:$(PATH) +# Path to java used to run MPLAB X when this makefile was created +MP_JAVA_PATH="/opt/microchip/mplabx/v5.25/sys/java/jre1.8.0_181/bin/" +OS_CURRENT="$(shell uname -s)" +MP_CC="/opt/microchip/xc8/v2.10/bin/xc8-cc" +# MP_CPPC is not defined +# MP_BC is not defined +MP_AS="/opt/microchip/xc8/v2.10/bin/xc8-cc" +MP_LD="/opt/microchip/xc8/v2.10/bin/xc8-cc" +MP_AR="/opt/microchip/xc8/v2.10/bin/xc8-ar" +DEP_GEN=${MP_JAVA_PATH}java -jar "/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/extractobjectdependencies.jar" +MP_CC_DIR="/opt/microchip/xc8/v2.10/bin" +# MP_CPPC_DIR is not defined +# MP_BC_DIR is not defined +MP_AS_DIR="/opt/microchip/xc8/v2.10/bin" +MP_LD_DIR="/opt/microchip/xc8/v2.10/bin" +MP_AR_DIR="/opt/microchip/xc8/v2.10/bin" +# MP_BC_DIR is not defined diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-variables.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-variables.mk new file mode 100644 index 0000000..1fc5ca7 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Makefile-variables.mk @@ -0,0 +1,13 @@ +# +# Generated - do not edit! +# +# NOCDDL +# +CND_BASEDIR=`pwd` +# default configuration +CND_ARTIFACT_DIR_default=dist/default/production +CND_ARTIFACT_NAME_default=tests3.X.production.hex +CND_ARTIFACT_PATH_default=dist/default/production/tests3.X.production.hex +CND_PACKAGE_DIR_default=${CND_DISTDIR}/default/package +CND_PACKAGE_NAME_default=tests3.x.tar +CND_PACKAGE_PATH_default=${CND_DISTDIR}/default/package/tests3.x.tar diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Package-default.bash b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Package-default.bash new file mode 100644 index 0000000..569eacd --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/Package-default.bash @@ -0,0 +1,73 @@ +#!/bin/bash -x + +# +# Generated - do not edit! +# + +# Macros +TOP=`pwd` +CND_CONF=default +CND_DISTDIR=dist +TMPDIR=build/${CND_CONF}/${IMAGE_TYPE}/tmp-packaging +TMPDIRNAME=tmp-packaging +OUTPUT_PATH=dist/${CND_CONF}/${IMAGE_TYPE}/tests3.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +OUTPUT_BASENAME=tests3.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +PACKAGE_TOP_DIR=tests3.x/ + +# Functions +function checkReturnCode +{ + rc=$? + if [ $rc != 0 ] + then + exit $rc + fi +} +function makeDirectory +# $1 directory path +# $2 permission (optional) +{ + mkdir -p "$1" + checkReturnCode + if [ "$2" != "" ] + then + chmod $2 "$1" + checkReturnCode + fi +} +function copyFileToTmpDir +# $1 from-file path +# $2 to-file path +# $3 permission +{ + cp "$1" "$2" + checkReturnCode + if [ "$3" != "" ] + then + chmod $3 "$2" + checkReturnCode + fi +} + +# Setup +cd "${TOP}" +mkdir -p ${CND_DISTDIR}/${CND_CONF}/package +rm -rf ${TMPDIR} +mkdir -p ${TMPDIR} + +# Copy files and create directories and links +cd "${TOP}" +makeDirectory ${TMPDIR}/tests3.x/bin +copyFileToTmpDir "${OUTPUT_PATH}" "${TMPDIR}/${PACKAGE_TOP_DIR}bin/${OUTPUT_BASENAME}" 0755 + + +# Generate tar file +cd "${TOP}" +rm -f ${CND_DISTDIR}/${CND_CONF}/package/tests3.x.tar +cd ${TMPDIR} +tar -vcf ../../../../${CND_DISTDIR}/${CND_CONF}/package/tests3.x.tar * +checkReturnCode + +# Cleanup +cd "${TOP}" +rm -rf ${TMPDIR} diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/configurations.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/configurations.xml new file mode 100644 index 0000000..70bc52a --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/configurations.xml @@ -0,0 +1,160 @@ + + + + + + + + + main.c + + + Makefile + + + Makefile + + + + localhost + ATtiny10 + + + + XC8 + 2.10 + 2 + + + + + + + + + + + + + false + false + + + + + + + false + + false + + false + false + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/private/configurations.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/private/configurations.xml new file mode 100644 index 0000000..e61d739 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/private/configurations.xml @@ -0,0 +1,25 @@ + + + Makefile + 0 + + + + /opt/microchip/xc8/v2.10/bin + + place holder 1 + place holder 2 + + + + + true + 0 + 0 + 0 + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/private/private.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/private/private.xml new file mode 100644 index 0000000..5e74fd2 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/private/private.xml @@ -0,0 +1,9 @@ + + + + + + file:/home/dev/Desktop/code/electronics/attiny10_mplab_test/tests4_timer_6000hz.X/main.c + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/project.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/project.xml new file mode 100644 index 0000000..9a5089c --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests4_timer_6000hz.X/nbproject/project.xml @@ -0,0 +1,32 @@ + + + com.microchip.mplab.nbide.embedded.makeproject + + + tests4_timer_6000hz + tests3 + tests2 + tests1 + test2 + test1 + 1f6b2f6c-8c6d-40dd-a737-d73d987b2bef + 0 + c + + + + ISO-8859-1 + + + + + default + 2 + + + + false + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/Makefile b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/Makefile new file mode 100644 index 0000000..fca8e2c --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/Makefile @@ -0,0 +1,113 @@ +# +# There exist several targets which are by default empty and which can be +# used for execution of your targets. These targets are usually executed +# before and after some main targets. They are: +# +# .build-pre: called before 'build' target +# .build-post: called after 'build' target +# .clean-pre: called before 'clean' target +# .clean-post: called after 'clean' target +# .clobber-pre: called before 'clobber' target +# .clobber-post: called after 'clobber' target +# .all-pre: called before 'all' target +# .all-post: called after 'all' target +# .help-pre: called before 'help' target +# .help-post: called after 'help' target +# +# Targets beginning with '.' are not intended to be called on their own. +# +# Main targets can be executed directly, and they are: +# +# build build a specific configuration +# clean remove built files from a configuration +# clobber remove all built files +# all build all configurations +# help print help mesage +# +# Targets .build-impl, .clean-impl, .clobber-impl, .all-impl, and +# .help-impl are implemented in nbproject/makefile-impl.mk. +# +# Available make variables: +# +# CND_BASEDIR base directory for relative paths +# CND_DISTDIR default top distribution directory (build artifacts) +# CND_BUILDDIR default top build directory (object files, ...) +# CONF name of current configuration +# CND_ARTIFACT_DIR_${CONF} directory of build artifact (current configuration) +# CND_ARTIFACT_NAME_${CONF} name of build artifact (current configuration) +# CND_ARTIFACT_PATH_${CONF} path to build artifact (current configuration) +# CND_PACKAGE_DIR_${CONF} directory of package (current configuration) +# CND_PACKAGE_NAME_${CONF} name of package (current configuration) +# CND_PACKAGE_PATH_${CONF} path to package (current configuration) +# +# NOCDDL + + +# Environment +MKDIR=mkdir +CP=cp +CCADMIN=CCadmin +RANLIB=ranlib + + +# build +build: .build-post + +.build-pre: +# Add your pre 'build' code here... + +.build-post: .build-impl +# Add your post 'build' code here... + + +# clean +clean: .clean-post + +.clean-pre: +# Add your pre 'clean' code here... +# WARNING: the IDE does not call this target since it takes a long time to +# simply run make. Instead, the IDE removes the configuration directories +# under build and dist directly without calling make. +# This target is left here so people can do a clean when running a clean +# outside the IDE. + +.clean-post: .clean-impl +# Add your post 'clean' code here... + + +# clobber +clobber: .clobber-post + +.clobber-pre: +# Add your pre 'clobber' code here... + +.clobber-post: .clobber-impl +# Add your post 'clobber' code here... + + +# all +all: .all-post + +.all-pre: +# Add your pre 'all' code here... + +.all-post: .all-impl +# Add your post 'all' code here... + + +# help +help: .help-post + +.help-pre: +# Add your pre 'help' code here... + +.help-post: .help-impl +# Add your post 'help' code here... + + + +# include project implementation makefile +include nbproject/Makefile-impl.mk + +# include project make variables +include nbproject/Makefile-variables.mk diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/build/default/production/main.o b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/build/default/production/main.o new file mode 100644 index 0000000000000000000000000000000000000000..caddc6e647a8260a22e2213b50ae0c338b4680d7 GIT binary patch literal 3172 zcma)8Piz!r6o22&wk))E+k!~M$buMZbZ1-slm;oZv``3?Hl>J(#9?-Jc6Y+g%sMk$ z3noHL44w>4F%sj!10FbeB7(8ev+?4=dk>zxaWnCNzc=%JyF-QOOJ=^`d++z&_rC9Y z^X=X^dG3@Df|LllKpl$#M{_IrmHbcn zm0c@4zBvEj#Fg`FvkxY(%&yJ+Ilq2s?bO;?*v_s^uTMT&zC%A786qvtmK8JSFBYao zMhb`YgZglx=z7I!!wl==BaHoGc-3hZ%dHwTvm92;$ONj`OO9oan^EL=*G4$X^1U!B zvb*Sb#b)5wT-$}cXjr4TngAxDAp<;nnAUApirDcY1L}Wvm(d$ilH5kA#CyVDLtM%jDnUG!5h~7 zAS&8k%VloM3!R#0SBh5M4AOepiK>p>sD#w(nvSPi)G2-14zEUjvt;=dyJR;obKrZ9 z6_(Ua7;dv+mW{{`qY}TuLq_Ddc3_MS4-eO`>+h;FZjTw!ofJ~wLP%>lUNmMzl==8R zdLScms?fxr$#j8`&_+g?ck?&qWj3{W?9XJo8opO6BzRMdpC;rILWh-0SpTMGg<&jV zseWJ_BGK3GO!2ko61+tu4vQaPPJ2iUh}Uyld$ion+{Nwzu^{@pQRZIi={W`?+HX5) zxg$Mq_ng^El-22YZ=&w&9T06kJgegJqprN0b(Jf*(| zd^DxM3C!zCIw|bL<_7x%RIl=AQgU;#V==lbGv?*CiW}=TNm3fYsW^*e*Fo8Os_b zn4|VV53jkAStcF7RmoUaD6*F$()ovt^l})I&IUboA?tzNFcWKh;E7(b@sn*hUe!l% zjLmX6u$L(9HUrbE*~l5ENNCS6H5|`YSx^?~mhZYYeq_>d)xdOdA^vaK2`1ksd9%J)97iUFkGk;`HrMfpB} zt}wgCut7tT!-MiQfYbB-hOPv;xLX55C2^YPWC^4$YgF@Ut29Vt=1?_guhHL);HVb + + + + bytes + 1024 + 106 + 918 + + + bytes + 32 + 0 + 32 + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/dist/default/production/tests5_timer_6000hz.X.production.elf b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/dist/default/production/tests5_timer_6000hz.X.production.elf new file mode 100755 index 0000000000000000000000000000000000000000..acb360cbbf18847dbbd3b4c7991946214b5ffb36 GIT binary patch literal 6012 zcmbW5No*U}8OPtukP@|++Pp6jt;n{#a7b$N5;--;! zMG_;IAjl<#9VCYwx&uXhC<+*@i>e~pQ_%!Y3p79u30$DP1T9bjMG+t<)c-d#k9?Z? zQ1k<5-uL~!@2&IZy*GS)CNV2X65}GXG~?Dd;Df!4<&loF0Qd;&XFZlb!!scLrgM3b z%D6fkqm4)-+z2%SjbP(k<80$h<8-6%)Zo_RzkdAW^R17zl#f~C%lkWzmmW^PytKLa zF#7W1=G+&{PhQ-d-CO`$*o;4kKDvd7!FxUTdVbz>ulGsvUi`_`N6EWAcYC&a?hf8P z`0no?&&6Vw0wd9DDeZ!`S~Rt}r4=nxt(J0yY_Xz^sgvrM7MYwp9hgwZ)i4{j8t7FR z^FU)Pf$J!)Gq{Fuagh)~9YGu)3nur#lzhqoByzhafP^s&4wJmf5q5`pPm1IaNZVPF z90O?|70FQ$-$jue0O`0Ql0lHpxJW3b>uVyJ0_k3|$PwJpp35M6zAnaG0r6iG$$5~T zmqaoN(wi5_MUcK5BDn<8UlYj$$bc!5age>=7RhrU``!@AD9HY|L^1|);2n{4gB*NM zBnrr(4@4q?9R99I7|4+yi9`lD`amT6K#u)PBm*GN{6ZvqK?XNP(hm~&tw{Pnj{i<1 zy&yx6MWTW{`-w<`Aj6-DE<$uP*szeF+wa{4QaI5YDs z$Qjw1#11(Fa@Hr35Xd>dNFpFi!yBNmPjUB1c&`GnNW^}P0>N@6xK_&63zs9LSA+E% z#aeK6V;xp@wVuzKS!j9vW-+H<&YEViayt?R$yFLe(&XdS#$$G^ zfh*l|Cu3eWXmf*hH}JVZhZ}UdL6;kJyTKke@Vh~e8}zzCpBwbM!GIg=b%T9wu-^?1 zxWPd;IOGP0-Qb8D9Cd?ZZt#p747x$U4UW6PkQ+Sf2E%S}!VONk!6`Qwaf8!taK;VJ zy1_X&uqL)|piA)`@vXG=Nh!&hqpq_7nKCw7c96p$?h!X7~_=Ka`zt8~+eYW=Xp5>R6~+GehO( zUT`aSA#`&Tdq4=QzjYNWxza{nXUtiWQ9|9!V|7yt_L0^r)54?pB}MM&M&IQQ588r} zw)#Q~lX6~CIywO0YqLhjzWbmn4xv0AD^D+S>_8+Yzdqa@kbi&&K*vcEs)_WdU%4ws z{hoJ}xZiu7^uHO-dimv94}W;63K)IT%7m|nnr7Ev(}x?4KoOe~fPN9|%V_XuYVo}SDi@4AqjNRQb)5Tc40shHb<2IO>Q8D^1lz8<_E1q{g@x$hfVJf3B_;07Tf<3Y#NUtT>Y3oe}pa8{~7G7 z&ig_6{|TE*05%rFUGbghteAfvY%Y|42)0;%*kw<_ra3}F<;P*S>X+G<;G(?%zgS-m zw*6IZkHd?MgwN$L=bzZJ+ z>bI!)RaAv-NH>g)8riJ|*cCbF{Ykh?p_Es)e7Lx$nHG1>0?XaNjGxz+ z%xpey*z>97jD(@juB4yV7xDQvN0zDe+hsGmiqtghw7@m%DXUiPYOY!?>-Z#8^Ey7` zwXBh?tm}1d7AtF2u4h+Q4gDs!Xx?yr4RfGrpc2k`Syp`!rdFz^uC7-$R2+R!AN@&S zS3m)3^9f9_QKnkRdNO0Q2>g#?{fC0sHfOEMKL|(22vqAyMs7tBNwi|>WX`}o3VpDNbtSw=yW2Y z_4!x0_%ndo)bBwTPf0&Td9Cw9bLnLd5JzpG@@Rki4ldf`xbU*K0C*fde>y)5@gSr; xj?N&$u(Hnw82eC& +#include +#include + +#include +//#include +//#include +//#include + +//tests5 tested and works (though 950Hz). unplug cable to programmer to see pin 4 active. + +//reference: https://www.avrfreaks.net/forum/sample-project-attiny10 +//https://blog.podkalicki.com/attiny13-blinky-with-timer-compa/ +//watchdog is too slow and inaccurate to get 6000Hz + +ISR(TIM0_COMPA_vect) +{ + // Toggle PB2 Hi/Low depending on current state + PINB = 1<<2; + //PORTB ^= _BV(LED_PIN); // toggle LED pin +} + + +/* + Delay in powerdown mode. Wake up by watchdog interrupt. + * //NOTE: see earlier code, e.g. tests3 in attiny10 elec projects 2020 + */ +/* +void delay_power_down_wdt(uint8_t wdto) +{ + wdt_reset(); + wdt_enable(wdto); + WDTCSR |= (1<.dep.inc +# @if [ -n "${MAKE_VERSION}" ]; then \ +# echo "DEPFILES=\$$(wildcard \$$(addsuffix .d, \$${OBJECTFILES}))" >>.dep.inc; \ +# echo "ifneq (\$${DEPFILES},)" >>.dep.inc; \ +# echo "include \$${DEPFILES}" >>.dep.inc; \ +# echo "endif" >>.dep.inc; \ +# else \ +# echo ".KEEP_STATE:" >>.dep.inc; \ +# echo ".KEEP_STATE_FILE:.make.state.\$${CONF}" >>.dep.inc; \ +# fi diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-local-default.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-local-default.mk new file mode 100644 index 0000000..62e3bb2 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-local-default.mk @@ -0,0 +1,36 @@ +# +# Generated Makefile - do not edit! +# +# +# This file contains information about the location of compilers and other tools. +# If you commmit this file into your revision control server, you will be able to +# to checkout the project and build it from the command line with make. However, +# if more than one person works on the same project, then this file might show +# conflicts since different users are bound to have compilers in different places. +# In that case you might choose to not commit this file and let MPLAB X recreate this file +# for each user. The disadvantage of not commiting this file is that you must run MPLAB X at +# least once so the file gets created and the project can be built. Finally, you can also +# avoid using this file at all if you are only building from the command line with make. +# You can invoke make with the values of the macros: +# $ makeMP_CC="/opt/microchip/mplabc30/v3.30c/bin/pic30-gcc" ... +# +PATH_TO_IDE_BIN=/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/ +# Adding MPLAB X bin directory to path. +PATH:=/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/:$(PATH) +# Path to java used to run MPLAB X when this makefile was created +MP_JAVA_PATH="/opt/microchip/mplabx/v5.25/sys/java/jre1.8.0_181/bin/" +OS_CURRENT="$(shell uname -s)" +MP_CC="/opt/microchip/xc8/v2.10/bin/xc8-cc" +# MP_CPPC is not defined +# MP_BC is not defined +MP_AS="/opt/microchip/xc8/v2.10/bin/xc8-cc" +MP_LD="/opt/microchip/xc8/v2.10/bin/xc8-cc" +MP_AR="/opt/microchip/xc8/v2.10/bin/xc8-ar" +DEP_GEN=${MP_JAVA_PATH}java -jar "/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/extractobjectdependencies.jar" +MP_CC_DIR="/opt/microchip/xc8/v2.10/bin" +# MP_CPPC_DIR is not defined +# MP_BC_DIR is not defined +MP_AS_DIR="/opt/microchip/xc8/v2.10/bin" +MP_LD_DIR="/opt/microchip/xc8/v2.10/bin" +MP_AR_DIR="/opt/microchip/xc8/v2.10/bin" +# MP_BC_DIR is not defined diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-variables.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-variables.mk new file mode 100644 index 0000000..5f55a8d --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Makefile-variables.mk @@ -0,0 +1,13 @@ +# +# Generated - do not edit! +# +# NOCDDL +# +CND_BASEDIR=`pwd` +# default configuration +CND_ARTIFACT_DIR_default=dist/default/production +CND_ARTIFACT_NAME_default=tests5_timer_6000hz.X.production.hex +CND_ARTIFACT_PATH_default=dist/default/production/tests5_timer_6000hz.X.production.hex +CND_PACKAGE_DIR_default=${CND_DISTDIR}/default/package +CND_PACKAGE_NAME_default=tests5timer6000hz.x.tar +CND_PACKAGE_PATH_default=${CND_DISTDIR}/default/package/tests5timer6000hz.x.tar diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Package-default.bash b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Package-default.bash new file mode 100644 index 0000000..a3c3cc9 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/Package-default.bash @@ -0,0 +1,73 @@ +#!/bin/bash -x + +# +# Generated - do not edit! +# + +# Macros +TOP=`pwd` +CND_CONF=default +CND_DISTDIR=dist +TMPDIR=build/${CND_CONF}/${IMAGE_TYPE}/tmp-packaging +TMPDIRNAME=tmp-packaging +OUTPUT_PATH=dist/${CND_CONF}/${IMAGE_TYPE}/tests5_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +OUTPUT_BASENAME=tests5_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +PACKAGE_TOP_DIR=tests5timer6000hz.x/ + +# Functions +function checkReturnCode +{ + rc=$? + if [ $rc != 0 ] + then + exit $rc + fi +} +function makeDirectory +# $1 directory path +# $2 permission (optional) +{ + mkdir -p "$1" + checkReturnCode + if [ "$2" != "" ] + then + chmod $2 "$1" + checkReturnCode + fi +} +function copyFileToTmpDir +# $1 from-file path +# $2 to-file path +# $3 permission +{ + cp "$1" "$2" + checkReturnCode + if [ "$3" != "" ] + then + chmod $3 "$2" + checkReturnCode + fi +} + +# Setup +cd "${TOP}" +mkdir -p ${CND_DISTDIR}/${CND_CONF}/package +rm -rf ${TMPDIR} +mkdir -p ${TMPDIR} + +# Copy files and create directories and links +cd "${TOP}" +makeDirectory ${TMPDIR}/tests5timer6000hz.x/bin +copyFileToTmpDir "${OUTPUT_PATH}" "${TMPDIR}/${PACKAGE_TOP_DIR}bin/${OUTPUT_BASENAME}" 0755 + + +# Generate tar file +cd "${TOP}" +rm -f ${CND_DISTDIR}/${CND_CONF}/package/tests5timer6000hz.x.tar +cd ${TMPDIR} +tar -vcf ../../../../${CND_DISTDIR}/${CND_CONF}/package/tests5timer6000hz.x.tar * +checkReturnCode + +# Cleanup +cd "${TOP}" +rm -rf ${TMPDIR} diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/configurations.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/configurations.xml new file mode 100644 index 0000000..70bc52a --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/configurations.xml @@ -0,0 +1,160 @@ + + + + + + + + + main.c + + + Makefile + + + Makefile + + + + localhost + ATtiny10 + + + + XC8 + 2.10 + 2 + + + + + + + + + + + + + false + false + + + + + + + false + + false + + false + false + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/private/configurations.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/private/configurations.xml new file mode 100644 index 0000000..e61d739 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/private/configurations.xml @@ -0,0 +1,25 @@ + + + Makefile + 0 + + + + /opt/microchip/xc8/v2.10/bin + + place holder 1 + place holder 2 + + + + + true + 0 + 0 + 0 + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/private/private.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/private/private.xml new file mode 100644 index 0000000..6807a2b --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/private/private.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/project.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/project.xml new file mode 100644 index 0000000..e57d1c8 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests5_timer_6000hz.X/nbproject/project.xml @@ -0,0 +1,33 @@ + + + com.microchip.mplab.nbide.embedded.makeproject + + + tests5_timer_6000hz + tests4_timer_6000hz + tests3 + tests2 + tests1 + test2 + test1 + 1f6b2f6c-8c6d-40dd-a737-d73d987b2bef + 0 + c + + + + ISO-8859-1 + + + + + default + 2 + + + + false + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/Makefile b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/Makefile new file mode 100644 index 0000000..fca8e2c --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/Makefile @@ -0,0 +1,113 @@ +# +# There exist several targets which are by default empty and which can be +# used for execution of your targets. These targets are usually executed +# before and after some main targets. They are: +# +# .build-pre: called before 'build' target +# .build-post: called after 'build' target +# .clean-pre: called before 'clean' target +# .clean-post: called after 'clean' target +# .clobber-pre: called before 'clobber' target +# .clobber-post: called after 'clobber' target +# .all-pre: called before 'all' target +# .all-post: called after 'all' target +# .help-pre: called before 'help' target +# .help-post: called after 'help' target +# +# Targets beginning with '.' are not intended to be called on their own. +# +# Main targets can be executed directly, and they are: +# +# build build a specific configuration +# clean remove built files from a configuration +# clobber remove all built files +# all build all configurations +# help print help mesage +# +# Targets .build-impl, .clean-impl, .clobber-impl, .all-impl, and +# .help-impl are implemented in nbproject/makefile-impl.mk. +# +# Available make variables: +# +# CND_BASEDIR base directory for relative paths +# CND_DISTDIR default top distribution directory (build artifacts) +# CND_BUILDDIR default top build directory (object files, ...) +# CONF name of current configuration +# CND_ARTIFACT_DIR_${CONF} directory of build artifact (current configuration) +# CND_ARTIFACT_NAME_${CONF} name of build artifact (current configuration) +# CND_ARTIFACT_PATH_${CONF} path to build artifact (current configuration) +# CND_PACKAGE_DIR_${CONF} directory of package (current configuration) +# CND_PACKAGE_NAME_${CONF} name of package (current configuration) +# CND_PACKAGE_PATH_${CONF} path to package (current configuration) +# +# NOCDDL + + +# Environment +MKDIR=mkdir +CP=cp +CCADMIN=CCadmin +RANLIB=ranlib + + +# build +build: .build-post + +.build-pre: +# Add your pre 'build' code here... + +.build-post: .build-impl +# Add your post 'build' code here... + + +# clean +clean: .clean-post + +.clean-pre: +# Add your pre 'clean' code here... +# WARNING: the IDE does not call this target since it takes a long time to +# simply run make. Instead, the IDE removes the configuration directories +# under build and dist directly without calling make. +# This target is left here so people can do a clean when running a clean +# outside the IDE. + +.clean-post: .clean-impl +# Add your post 'clean' code here... + + +# clobber +clobber: .clobber-post + +.clobber-pre: +# Add your pre 'clobber' code here... + +.clobber-post: .clobber-impl +# Add your post 'clobber' code here... + + +# all +all: .all-post + +.all-pre: +# Add your pre 'all' code here... + +.all-post: .all-impl +# Add your post 'all' code here... + + +# help +help: .help-post + +.help-pre: +# Add your pre 'help' code here... + +.help-post: .help-impl +# Add your post 'help' code here... + + + +# include project implementation makefile +include nbproject/Makefile-impl.mk + +# include project make variables +include nbproject/Makefile-variables.mk diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/build/default/production/main.o b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/build/default/production/main.o new file mode 100644 index 0000000000000000000000000000000000000000..968d9e4aeb924f57a48eca17f77e56b08dae41f6 GIT binary patch literal 3280 zcma)8&2QX96rZto(@hid)zTIUWPv~fbiGMGLKH}wG~4f{3F)T7+}At|+u>$m zW%~BHYwUYnVN8wkr}+M(C$cl6quHI>4s9fxbKG3HW(3vAQNms>IBVB)#YP31Q4C5( zXaJS0MccF{jWD#`^P?1HdTtQr$epv@T;2C7j^)5!H_WrSlI>6CtDa-!5t!E;vs%~5 z5#(oW)A!7(UC&P+r(Akr-+X?XHljsI9kVfMEc)cg<|?H(4Zob*p3Tjnv~s!OnxXBv zxxk9X0JdoQgdR;Egnq*e;SH*uALcB#;Sjgs26n}@N;$J?_({EJhh^KUl>*l77`CgK ztX+D+3eJXJJ#Ts?D{s{>v+udK8RX?o=uW+66!p*w!aTi#F+H>$%h$(7Mn6`#D!$35T-V4HyqbPrd<3SU7_%dEHw5jN*aWiHj3m-x%?aPlr=3L`IS_<=DC$@ zjMqf?UP2}&v{{*$^>1p5>-r*=>iPOk#`{{m%0J<0PFuwI1pfx+q=)f-{!C_Fmzvp} zInmM27kFO>${b={UAtgJ`)y!qW}@q*u7m3sOKEI(cdTyd?&kx1YVAjRx*1C+?FZLg z3gmKCYvCb)0DZxaZZ-P`0aY*T%H% z`smo$bMX;Jv8)fzT?l8&rJ?Suas%srj2uE}7pHsFC1tuN^?_RGNncAb)ZLQ%?QZMq zgOy@;?zYGPYP&ZgvnsxuhDQ-NpE)?IaIc0m49HBzIK(~u9O@qDlG^G?fn4qQ(uzM zUJo$TE1FH$kIm}`be%=uNDLPC?vKFC%zQM4PF?q{N`x<1zSmM(2RS;pTajDsVvI%{ zPsYVZehVLyKLi8hDq*qwN%S@EjqTF{Q@y7MBM-@|0#n^lPO(%PWbAt2Eb>t7CbElI z>cK29#ga%q?KWZJQ=dpal}niTuMrltT}*Jwz=N<8w&_({mgPKVQkXvTr!J zYX7%v29xe0>OGS9e^iX=E$^u(1&;p*J(#xzJo@JU#oH?KCFiAnk|O8b14FXDlh9?q z6Ib%+?xVh&!b9>N5>t;ojE8P7@{zuPN5%lMD|k$WP%P3n3pJVVI`SQdjq=g$CG))w zEMoxKpU7nr5F&kVK$np(pd5M!sKRqkKKWM|p4HkuiYm6$(m- z^nD2%VXBFQcoLINK6;vB#1P39@Cs7FDAV5(cuM$&(2NIwsXn@Ah)4C&Re&Y7qz2wE nEv;QU&7Eiu_A?UHVWfMIa#B9JAL$n{nQvV53(S#F9+H0mG55Fa literal 0 HcmV?d00001 diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/build/default/production/main.o.d b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/build/default/production/main.o.d new file mode 100644 index 0000000..a491c02 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/build/default/production/main.o.d @@ -0,0 +1,55 @@ +build/default/production/main.o.d build/default/production/main.o: main.c \ + /opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/xc.h \ + /opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/cci.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/io.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/sfr_defs.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/inttypes.h \ + /opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/stdint.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/stdint.h \ + /home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10/include/avr/iotn10.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/portpins.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/common.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/version.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/xmega.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/fuse.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/lock.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/util/delay.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/util/delay_basic.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/math.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/interrupt.h + +/opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/xc.h: + +/opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/cci.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/io.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/sfr_defs.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/inttypes.h: + +/opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/stdint.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/stdint.h: + +/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10/include/avr/iotn10.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/portpins.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/common.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/version.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/xmega.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/fuse.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/lock.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/util/delay.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/util/delay_basic.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/math.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/interrupt.h: diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/memoryfile.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/memoryfile.xml new file mode 100644 index 0000000..36246f7 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/memoryfile.xml @@ -0,0 +1,17 @@ + + + + + bytes + 1024 + 124 + 900 + + + bytes + 32 + 0 + 32 + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/tests6_timer_6000hz.X.production.elf b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/dist/default/production/tests6_timer_6000hz.X.production.elf new file mode 100755 index 0000000000000000000000000000000000000000..ea25b6fe0f029c5a666f862cebb5a5e15d999ee2 GIT binary patch literal 6060 zcmbW5S!^4}8OLXLNr^g4UA`~TifqXTm!z)PvK^ZuB}LXjm7*N?A=pslN+iq+t&g^}XRP+wi^f{kGG>=njYP4SOJ$PTf-$O3 z=%YqxV&bfCTp!beY>+qEtuf|;#Mmu719;Bi(ea3+z=OI5KQTH??SiU!v_r_$R+kSM zV;C-`xV2;K0dt>`$q|s2^D;RB(mEoO;~<_(GC2g&c1|26a+~X3l+;x zW`DNeFO`cMc{2}QN~Ui6)7kRXK&F^C11K2K^Qlb9AVVdvm`#<7sZ6#M2q!3(5uI5M zjOam~2hFE8uO{!5$>8&Eq`#Cbulq-R{ur9JzP?#VS=nO2Uom-J0prz6I`77|h()X;o^bPavvFi`@_(HH2xK z*@AV^u$cP#5An09ibpimwyUZe4z^ne!I}Etx8$d`HvGu0y4<;9VZ&$3tz6#g;ISQ= zULM=)zg=C5VcbDii)CY+DcuV7;XWSaUB#`?5HV#^`8gV)&{|7YSeVkIoc4CNplO3l z^LBK+)PX726kTJWlO2~k=K8L6s_l%qouI`DTAje-1Z_^x?gSl9(CGyGoWSb@T~5&L z1U*jB>jZsHu-^#|IKe?DIOGI}o#2QQ9CdO{zmBx#2!Q?oZUZ zyNzjwRauPQdpZ^d&8SA(h)qn~c?$WJIV~X{>H~#y;e_ zRa$toZbehuI(gq+c&lwKXc5Mn_lTA!dvpLWI^-eVG+w;@b{Wk}B{g502XBqb+!JLe zRyQK;A}LILW3bbwejh*2aWG2M4(fZ@t36c1Uf0`N)a!oiVrT_V)CxL~qHF$Kb}i+j z?Jmf~x=%S@*u&Aq)mtnajV#b>B_6i3DHffJ#)B*jR2L(WWwwI9`1CA`EX*&$fNU9A zY$Xy2FR+!xNSrOlRR-Z{U zRFpKfkLNUGlr-k8_sG^=Y-g7u(C2F>1$Vz@BKuLO!wsacvkjT9Q#-ps=r1+c&Mw_- zu1fk8WczMIaA$WO?<*wow6nW{oW2=5?d%#5dV~u9h6sV`%OMy2p?I%D7vtf>c+l-a z^rsv4$IyLvD3SgnTWshbKx+Cc>|^L6em6#oPV6FnH{$<&k9}wN-;$l`r!%%3?qW0c{E)bP}Qz-DE^523k)}da^ zkMBXJ?}rlkZ$X#a{}FT=4_cRcF@JssU9SIA=-2Dt2bKRPbdh|}u@LU@Z%1e4@&`oc zQHaV9K$q(eI`k{hX^v2$_)+N1`c?KBxUA2^F4vcWZr|DM@wf@SS>Mj?nq=?Acx4>r zE$E_))ZVwCivc8^(M`k17P1!8u?rzH%)41jFEYcZ;DTV#1*n|Ni|xuVR+f#I4FhHf z3$}penhRLId2Z!PM%mop@_n;hY$&|4TrrtO>|_~riQ{;P8N7DGETloB;Y8R#)VbJ_ zu`s>4YO7MB;o zQ^wTl+(NX$jkLL*+{{TMGY;Fz-0V^~u^OL#PPKHK5#8oj7*T~WhLZ9?N+XsrlcjoZ z>LYNe*@O{@+(GdN!_BLBXP zk!5=2UfxQsA-BqQo)HrNm33abo+{?^CN7M6+QcQ_NS2d@4YMNDY+=19$I%D%(Z3Mv3dlik`~u@_gy|gdUuKjRf&Ve_ z|FFQfrM^}rAd7XLLeOVS=@cINzUiM%w2nL@C?)aj4}pOvX0RGj@7eg`BV#IHL1eu=~FVG&HSy;Ya#L`3WJZ}5oU0AfRa1X(^MZ6jXu z{Lol>*?aJ#Hc&j;-$)<8Ba(={1t9$B_owp%?QJ3nKRSa*!^*t)N7{$N3AyMm<)RFk fkK@R-j6tLFbnd6|qw@`& +#include +#include + +#include +//#include +//#include +//#include + + + +//tests5 tested and works (at ~950hz). unplug cable to programmer to see pin 4 active. +//however... +//tests6 DEADEND +//never worked right. giving up and using delay. + +//reference: https://www.avrfreaks.net/forum/sample-project-attiny10 +//https://blog.podkalicki.com/attiny13-blinky-with-timer-compa/ +//watchdog is too slow and inaccurate to get 6000Hz + +ISR(TIM0_COMPA_vect) +{ + // Toggle PB2 Hi/Low depending on current state + PINB = 1<<2; + TIFR0 |= 1< 256? (test) + + //520 about 950hz, 25us wide pulse + //OCR0A = 520; // with one timer, ever 166.667hz we want to count once (3000hz) + + //OCR0A = 1; //475hz + + //this goes to 475hz (pulses). doesn't make sense. +//// OCR0AH = 0xFF; // +//// OCR0AL = 0xFF; + + //attiny10 output compare broken apparently + //this still 960hz, with 100us or so pulse size (high is 100us, low is longer) + //OCR0A = 100; + + + //inline asm to load values into 16 bit register + + //; variables + //; For 1 Hz output, the timer delay has to be 1/2 second (1/2 second on / 1/2 second off) + //; delay = OCR0A * 1024 * 8 / 8000000 + //; for 1/2 second, OCR0A = 488 (0x01E8) + //.EQU OCR0AHigh = 0x01 + //.EQU OCR0ALow = 0xe8 + // in bash type: printf "%x\n" 488 + //.EQU OCR0AHigh = 0x02 + //.EQU OCR0ALow = 0x08 + + // ldi r17, OCR0AHigh //; Sets the output compare register value + //ldi r16, OCR0ALow + + //this asm doesn't work (why?) //perhaps OCR0A is really just 8 bits on attiny10...?) +////// asm volatile( +////// "ldi r17, 0x02" +////// "ldi r16, 0x08" +////// "out OCR0AH, r17" +////// "out OCR0AL, r16" +////// ); + + //this asm works +// asm volatile("nop\n\t" +//"nop\n\t" +//"nop\n\t" +//"nop\n\t" +//::); + + TIMSK0 |= _BV(OCIE0A); // enable Timer CTC interrupt + + // PB2 change to output + DDRB = 1<<2; + sei(); + + while(1) + { + //handled by interrupt + + } +} + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-default.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-default.mk new file mode 100644 index 0000000..17731d0 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-default.mk @@ -0,0 +1,158 @@ +# +# Generated Makefile - do not edit! +# +# Edit the Makefile in the project folder instead (../Makefile). Each target +# has a -pre and a -post target defined where you can add customized code. +# +# This makefile implements configuration specific macros and targets. + + +# Include project Makefile +ifeq "${IGNORE_LOCAL}" "TRUE" +# do not include local makefile. User is passing all local related variables already +else +include Makefile +# Include makefile containing local settings +ifeq "$(wildcard nbproject/Makefile-local-default.mk)" "nbproject/Makefile-local-default.mk" +include nbproject/Makefile-local-default.mk +endif +endif + +# Environment +MKDIR=mkdir -p +RM=rm -f +MV=mv +CP=cp + +# Macros +CND_CONF=default +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +IMAGE_TYPE=debug +OUTPUT_SUFFIX=elf +DEBUGGABLE_SUFFIX=elf +FINAL_IMAGE=dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +else +IMAGE_TYPE=production +OUTPUT_SUFFIX=hex +DEBUGGABLE_SUFFIX=elf +FINAL_IMAGE=dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +endif + +ifeq ($(COMPARE_BUILD), true) +COMPARISON_BUILD= +else +COMPARISON_BUILD= +endif + +ifdef SUB_IMAGE_ADDRESS + +else +SUB_IMAGE_ADDRESS_COMMAND= +endif + +# Object Directory +OBJECTDIR=build/${CND_CONF}/${IMAGE_TYPE} + +# Distribution Directory +DISTDIR=dist/${CND_CONF}/${IMAGE_TYPE} + +# Source Files Quoted if spaced +SOURCEFILES_QUOTED_IF_SPACED=main.c + +# Object Files Quoted if spaced +OBJECTFILES_QUOTED_IF_SPACED=${OBJECTDIR}/main.o +POSSIBLE_DEPFILES=${OBJECTDIR}/main.o.d + +# Object Files +OBJECTFILES=${OBJECTDIR}/main.o + +# Source Files +SOURCEFILES=main.c + + + +CFLAGS= +ASFLAGS= +LDLIBSOPTIONS= + +############# Tool locations ########################################## +# If you copy a project from one host to another, the path where the # +# compiler is installed may be different. # +# If you open this project with MPLAB X in the new host, this # +# makefile will be regenerated and the paths will be corrected. # +####################################################################### +# fixDeps replaces a bunch of sed/cat/printf statements that slow down the build +FIXDEPS=fixDeps + +.build-conf: ${BUILD_SUBPROJECTS} +ifneq ($(INFORMATION_MESSAGE), ) + @echo $(INFORMATION_MESSAGE) +endif + ${MAKE} -f nbproject/Makefile-default.mk dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} + +MP_PROCESSOR_OPTION=ATtiny10 +# ------------------------------------------------------------------------------------ +# Rules for buildStep: compile +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +${OBJECTDIR}/main.o: main.c nbproject/Makefile-${CND_CONF}.mk + @${MKDIR} "${OBJECTDIR}" + @${RM} ${OBJECTDIR}/main.o.d + @${RM} ${OBJECTDIR}/main.o + ${MP_CC} $(MP_EXTRA_CC_PRE) -mcpu=$(MP_PROCESSOR_OPTION) -c -D__DEBUG=1 -g -DDEBUG -gdwarf-2 -x c -D__$(MP_PROCESSOR_OPTION)__ -mdfp="/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10" -Wl,--gc-sections -O1 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -funsigned-char -funsigned-bitfields -Wall -DXPRJ_default=$(CND_CONF) $(COMPARISON_BUILD) -gdwarf-3 -MD -MP -MF "${OBJECTDIR}/main.o.d" -MT "${OBJECTDIR}/main.o.d" -MT ${OBJECTDIR}/main.o -o ${OBJECTDIR}/main.o main.c + +else +${OBJECTDIR}/main.o: main.c nbproject/Makefile-${CND_CONF}.mk + @${MKDIR} "${OBJECTDIR}" + @${RM} ${OBJECTDIR}/main.o.d + @${RM} ${OBJECTDIR}/main.o + ${MP_CC} $(MP_EXTRA_CC_PRE) -mcpu=$(MP_PROCESSOR_OPTION) -c -x c -D__$(MP_PROCESSOR_OPTION)__ -mdfp="/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10" -Wl,--gc-sections -O1 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -funsigned-char -funsigned-bitfields -Wall -DXPRJ_default=$(CND_CONF) $(COMPARISON_BUILD) -gdwarf-3 -MD -MP -MF "${OBJECTDIR}/main.o.d" -MT "${OBJECTDIR}/main.o.d" -MT ${OBJECTDIR}/main.o -o ${OBJECTDIR}/main.o main.c + +endif + +# ------------------------------------------------------------------------------------ +# Rules for buildStep: assemble +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +else +endif + +# ------------------------------------------------------------------------------------ +# Rules for buildStep: assembleWithPreprocess +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +else +endif + +# ------------------------------------------------------------------------------------ +# Rules for buildStep: link +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}: ${OBJECTFILES} nbproject/Makefile-${CND_CONF}.mk + @${MKDIR} dist/${CND_CONF}/${IMAGE_TYPE} + ${MP_CC} $(MP_EXTRA_LD_PRE) -mcpu=$(MP_PROCESSOR_OPTION) -Wl,-Map=dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.map -D__DEBUG=1 -DXPRJ_default=$(CND_CONF) -Wl,--defsym=__MPLAB_BUILD=1 -mdfp="/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10" -gdwarf-2 -Wl,--gc-sections -O1 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -funsigned-char -funsigned-bitfields -Wall -gdwarf-3 $(COMPARISON_BUILD) -Wl,--memorysummary,dist/${CND_CONF}/${IMAGE_TYPE}/memoryfile.xml -o dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX} -o dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} ${OBJECTFILES_QUOTED_IF_SPACED} -Wl,--start-group -Wl,-lm -Wl,--end-group -Wl,--defsym=__MPLAB_DEBUG=1,--defsym=__DEBUG=1 + @${RM} dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.hex + +else +dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}: ${OBJECTFILES} nbproject/Makefile-${CND_CONF}.mk + @${MKDIR} dist/${CND_CONF}/${IMAGE_TYPE} + ${MP_CC} $(MP_EXTRA_LD_PRE) -mcpu=$(MP_PROCESSOR_OPTION) -Wl,-Map=dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.map -DXPRJ_default=$(CND_CONF) -Wl,--defsym=__MPLAB_BUILD=1 -mdfp="/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10" -Wl,--gc-sections -O1 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -funsigned-char -funsigned-bitfields -Wall -gdwarf-3 $(COMPARISON_BUILD) -Wl,--memorysummary,dist/${CND_CONF}/${IMAGE_TYPE}/memoryfile.xml -o dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX} -o dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX} ${OBJECTFILES_QUOTED_IF_SPACED} -Wl,--start-group -Wl,-lm -Wl,--end-group + ${MP_CC_DIR}/avr-objcopy -O ihex "dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX}" "dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.hex" +endif + + +# Subprojects +.build-subprojects: + + +# Subprojects +.clean-subprojects: + +# Clean Targets +.clean-conf: ${CLEAN_SUBPROJECTS} + ${RM} -r build/default + ${RM} -r dist/default + +# Enable dependency checking +.dep.inc: .depcheck-impl + +DEPFILES=$(shell "${PATH_TO_IDE_BIN}"mplabwildcard ${POSSIBLE_DEPFILES}) +ifneq (${DEPFILES},) +include ${DEPFILES} +endif diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-genesis.properties b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-genesis.properties new file mode 100644 index 0000000..3eaed46 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-genesis.properties @@ -0,0 +1,10 @@ +# +#Wed Jul 15 00:53:34 EDT 2020 +default.Pack.dfplocation=/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10 +default.languagetoolchain.dir=/opt/microchip/xc8/v2.10/bin +configurations-xml=5e854234238a55dafe0eba84ce6d1401 +com-microchip-mplab-nbide-embedded-makeproject-MakeProject.md5=6e453b0cf7f7da72a932cfdb2f655401 +default.languagetoolchain.version=2.10 +host.platform=linux +conf.ids=default +default.com-microchip-mplab-nbide-toolchainXC8-XC8LanguageToolchain.md5=23d12c447ed4f9462f01e2202bc2f36a diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-impl.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-impl.mk new file mode 100644 index 0000000..04b7264 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-impl.mk @@ -0,0 +1,69 @@ +# +# Generated Makefile - do not edit! +# +# Edit the Makefile in the project folder instead (../Makefile). Each target +# has a pre- and a post- target defined where you can add customization code. +# +# This makefile implements macros and targets common to all configurations. +# +# NOCDDL + + +# Building and Cleaning subprojects are done by default, but can be controlled with the SUB +# macro. If SUB=no, subprojects will not be built or cleaned. The following macro +# statements set BUILD_SUB-CONF and CLEAN_SUB-CONF to .build-reqprojects-conf +# and .clean-reqprojects-conf unless SUB has the value 'no' +SUB_no=NO +SUBPROJECTS=${SUB_${SUB}} +BUILD_SUBPROJECTS_=.build-subprojects +BUILD_SUBPROJECTS_NO= +BUILD_SUBPROJECTS=${BUILD_SUBPROJECTS_${SUBPROJECTS}} +CLEAN_SUBPROJECTS_=.clean-subprojects +CLEAN_SUBPROJECTS_NO= +CLEAN_SUBPROJECTS=${CLEAN_SUBPROJECTS_${SUBPROJECTS}} + + +# Project Name +PROJECTNAME=tests6_timer_6000hz.X + +# Active Configuration +DEFAULTCONF=default +CONF=${DEFAULTCONF} + +# All Configurations +ALLCONFS=default + + +# build +.build-impl: .build-pre + ${MAKE} -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .build-conf + + +# clean +.clean-impl: .clean-pre + ${MAKE} -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .clean-conf + +# clobber +.clobber-impl: .clobber-pre .depcheck-impl + ${MAKE} SUBPROJECTS=${SUBPROJECTS} CONF=default clean + + + +# all +.all-impl: .all-pre .depcheck-impl + ${MAKE} SUBPROJECTS=${SUBPROJECTS} CONF=default build + + + +# dependency checking support +.depcheck-impl: +# @echo "# This code depends on make tool being used" >.dep.inc +# @if [ -n "${MAKE_VERSION}" ]; then \ +# echo "DEPFILES=\$$(wildcard \$$(addsuffix .d, \$${OBJECTFILES}))" >>.dep.inc; \ +# echo "ifneq (\$${DEPFILES},)" >>.dep.inc; \ +# echo "include \$${DEPFILES}" >>.dep.inc; \ +# echo "endif" >>.dep.inc; \ +# else \ +# echo ".KEEP_STATE:" >>.dep.inc; \ +# echo ".KEEP_STATE_FILE:.make.state.\$${CONF}" >>.dep.inc; \ +# fi diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-local-default.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-local-default.mk new file mode 100644 index 0000000..62e3bb2 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-local-default.mk @@ -0,0 +1,36 @@ +# +# Generated Makefile - do not edit! +# +# +# This file contains information about the location of compilers and other tools. +# If you commmit this file into your revision control server, you will be able to +# to checkout the project and build it from the command line with make. However, +# if more than one person works on the same project, then this file might show +# conflicts since different users are bound to have compilers in different places. +# In that case you might choose to not commit this file and let MPLAB X recreate this file +# for each user. The disadvantage of not commiting this file is that you must run MPLAB X at +# least once so the file gets created and the project can be built. Finally, you can also +# avoid using this file at all if you are only building from the command line with make. +# You can invoke make with the values of the macros: +# $ makeMP_CC="/opt/microchip/mplabc30/v3.30c/bin/pic30-gcc" ... +# +PATH_TO_IDE_BIN=/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/ +# Adding MPLAB X bin directory to path. +PATH:=/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/:$(PATH) +# Path to java used to run MPLAB X when this makefile was created +MP_JAVA_PATH="/opt/microchip/mplabx/v5.25/sys/java/jre1.8.0_181/bin/" +OS_CURRENT="$(shell uname -s)" +MP_CC="/opt/microchip/xc8/v2.10/bin/xc8-cc" +# MP_CPPC is not defined +# MP_BC is not defined +MP_AS="/opt/microchip/xc8/v2.10/bin/xc8-cc" +MP_LD="/opt/microchip/xc8/v2.10/bin/xc8-cc" +MP_AR="/opt/microchip/xc8/v2.10/bin/xc8-ar" +DEP_GEN=${MP_JAVA_PATH}java -jar "/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/extractobjectdependencies.jar" +MP_CC_DIR="/opt/microchip/xc8/v2.10/bin" +# MP_CPPC_DIR is not defined +# MP_BC_DIR is not defined +MP_AS_DIR="/opt/microchip/xc8/v2.10/bin" +MP_LD_DIR="/opt/microchip/xc8/v2.10/bin" +MP_AR_DIR="/opt/microchip/xc8/v2.10/bin" +# MP_BC_DIR is not defined diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-variables.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-variables.mk new file mode 100644 index 0000000..ad24229 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Makefile-variables.mk @@ -0,0 +1,13 @@ +# +# Generated - do not edit! +# +# NOCDDL +# +CND_BASEDIR=`pwd` +# default configuration +CND_ARTIFACT_DIR_default=dist/default/production +CND_ARTIFACT_NAME_default=tests6_timer_6000hz.X.production.hex +CND_ARTIFACT_PATH_default=dist/default/production/tests6_timer_6000hz.X.production.hex +CND_PACKAGE_DIR_default=${CND_DISTDIR}/default/package +CND_PACKAGE_NAME_default=tests6timer6000hz.x.tar +CND_PACKAGE_PATH_default=${CND_DISTDIR}/default/package/tests6timer6000hz.x.tar diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Package-default.bash b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Package-default.bash new file mode 100644 index 0000000..e835b4e --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/Package-default.bash @@ -0,0 +1,73 @@ +#!/bin/bash -x + +# +# Generated - do not edit! +# + +# Macros +TOP=`pwd` +CND_CONF=default +CND_DISTDIR=dist +TMPDIR=build/${CND_CONF}/${IMAGE_TYPE}/tmp-packaging +TMPDIRNAME=tmp-packaging +OUTPUT_PATH=dist/${CND_CONF}/${IMAGE_TYPE}/tests6_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +OUTPUT_BASENAME=tests6_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +PACKAGE_TOP_DIR=tests6timer6000hz.x/ + +# Functions +function checkReturnCode +{ + rc=$? + if [ $rc != 0 ] + then + exit $rc + fi +} +function makeDirectory +# $1 directory path +# $2 permission (optional) +{ + mkdir -p "$1" + checkReturnCode + if [ "$2" != "" ] + then + chmod $2 "$1" + checkReturnCode + fi +} +function copyFileToTmpDir +# $1 from-file path +# $2 to-file path +# $3 permission +{ + cp "$1" "$2" + checkReturnCode + if [ "$3" != "" ] + then + chmod $3 "$2" + checkReturnCode + fi +} + +# Setup +cd "${TOP}" +mkdir -p ${CND_DISTDIR}/${CND_CONF}/package +rm -rf ${TMPDIR} +mkdir -p ${TMPDIR} + +# Copy files and create directories and links +cd "${TOP}" +makeDirectory ${TMPDIR}/tests6timer6000hz.x/bin +copyFileToTmpDir "${OUTPUT_PATH}" "${TMPDIR}/${PACKAGE_TOP_DIR}bin/${OUTPUT_BASENAME}" 0755 + + +# Generate tar file +cd "${TOP}" +rm -f ${CND_DISTDIR}/${CND_CONF}/package/tests6timer6000hz.x.tar +cd ${TMPDIR} +tar -vcf ../../../../${CND_DISTDIR}/${CND_CONF}/package/tests6timer6000hz.x.tar * +checkReturnCode + +# Cleanup +cd "${TOP}" +rm -rf ${TMPDIR} diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/configurations.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/configurations.xml new file mode 100644 index 0000000..70bc52a --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/configurations.xml @@ -0,0 +1,160 @@ + + + + + + + + + main.c + + + Makefile + + + Makefile + + + + localhost + ATtiny10 + + + + XC8 + 2.10 + 2 + + + + + + + + + + + + + false + false + + + + + + + false + + false + + false + false + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/private/configurations.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/private/configurations.xml new file mode 100644 index 0000000..e61d739 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/private/configurations.xml @@ -0,0 +1,25 @@ + + + Makefile + 0 + + + + /opt/microchip/xc8/v2.10/bin + + place holder 1 + place holder 2 + + + + + true + 0 + 0 + 0 + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/private/private.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/private/private.xml new file mode 100644 index 0000000..d45790b --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/private/private.xml @@ -0,0 +1,9 @@ + + + + + + file:/home/dev/Desktop/code/electronics/attiny10_mplab_test/tests6_timer_6000hz.X/main.c + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/project.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/project.xml new file mode 100644 index 0000000..f50959a --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests6_timer_6000hz.X/nbproject/project.xml @@ -0,0 +1,34 @@ + + + com.microchip.mplab.nbide.embedded.makeproject + + + tests6_timer_6000hz + tests5_timer_6000hz + tests4_timer_6000hz + tests3 + tests2 + tests1 + test2 + test1 + 1f6b2f6c-8c6d-40dd-a737-d73d987b2bef + 0 + c + + + + ISO-8859-1 + + + + + default + 2 + + + + false + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/Makefile b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/Makefile new file mode 100644 index 0000000..fca8e2c --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/Makefile @@ -0,0 +1,113 @@ +# +# There exist several targets which are by default empty and which can be +# used for execution of your targets. These targets are usually executed +# before and after some main targets. They are: +# +# .build-pre: called before 'build' target +# .build-post: called after 'build' target +# .clean-pre: called before 'clean' target +# .clean-post: called after 'clean' target +# .clobber-pre: called before 'clobber' target +# .clobber-post: called after 'clobber' target +# .all-pre: called before 'all' target +# .all-post: called after 'all' target +# .help-pre: called before 'help' target +# .help-post: called after 'help' target +# +# Targets beginning with '.' are not intended to be called on their own. +# +# Main targets can be executed directly, and they are: +# +# build build a specific configuration +# clean remove built files from a configuration +# clobber remove all built files +# all build all configurations +# help print help mesage +# +# Targets .build-impl, .clean-impl, .clobber-impl, .all-impl, and +# .help-impl are implemented in nbproject/makefile-impl.mk. +# +# Available make variables: +# +# CND_BASEDIR base directory for relative paths +# CND_DISTDIR default top distribution directory (build artifacts) +# CND_BUILDDIR default top build directory (object files, ...) +# CONF name of current configuration +# CND_ARTIFACT_DIR_${CONF} directory of build artifact (current configuration) +# CND_ARTIFACT_NAME_${CONF} name of build artifact (current configuration) +# CND_ARTIFACT_PATH_${CONF} path to build artifact (current configuration) +# CND_PACKAGE_DIR_${CONF} directory of package (current configuration) +# CND_PACKAGE_NAME_${CONF} name of package (current configuration) +# CND_PACKAGE_PATH_${CONF} path to package (current configuration) +# +# NOCDDL + + +# Environment +MKDIR=mkdir +CP=cp +CCADMIN=CCadmin +RANLIB=ranlib + + +# build +build: .build-post + +.build-pre: +# Add your pre 'build' code here... + +.build-post: .build-impl +# Add your post 'build' code here... + + +# clean +clean: .clean-post + +.clean-pre: +# Add your pre 'clean' code here... +# WARNING: the IDE does not call this target since it takes a long time to +# simply run make. Instead, the IDE removes the configuration directories +# under build and dist directly without calling make. +# This target is left here so people can do a clean when running a clean +# outside the IDE. + +.clean-post: .clean-impl +# Add your post 'clean' code here... + + +# clobber +clobber: .clobber-post + +.clobber-pre: +# Add your pre 'clobber' code here... + +.clobber-post: .clobber-impl +# Add your post 'clobber' code here... + + +# all +all: .all-post + +.all-pre: +# Add your pre 'all' code here... + +.all-post: .all-impl +# Add your post 'all' code here... + + +# help +help: .help-post + +.help-pre: +# Add your pre 'help' code here... + +.help-post: .help-impl +# Add your post 'help' code here... + + + +# include project implementation makefile +include nbproject/Makefile-impl.mk + +# include project make variables +include nbproject/Makefile-variables.mk diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/build/default/production/main.o b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/build/default/production/main.o new file mode 100644 index 0000000000000000000000000000000000000000..0d4262d1568bb06d7028985bab37de89598ff8e3 GIT binary patch literal 2808 zcma)7&2QX96rZs-$>yV>X&{PPB(_l0qGCInhO{cp$2Mt0q?SZ&3P>QiUaxo8>e^n} z-jEiFqV`aP5FB#gQaB;;A?_8NKCYw!<;@VIN};pq$DKj<7K{%6{9tzsc_Xa_5gbm95pS+SUW>FYEHn zU+w!V<2Uzj{ceaI94)N z5U^hFgl_6bp^P)S@XlZl`|W#rE{X z#6ZI}BJdqM5!t{T%Nor*ktt$A3^NkKg7!8;su|nf5UzKEhutjt=U@1I0_dBm4s2 z+Y8MhHaIv7A?j<4>BWLm}fCi zouEQC(=^#dkAqJk(%1^k{O{obhUTHHxfQijE9jQjhI_(VpF~+%D5z}sq1)=zJjTQ; zV^fmWaDiqs@3@{U4SkO5v;FX^7y5^w&i$X$oyN^mu zRDo?@T(w`bZI*#^Ik<3UDFX`&tJ#_cZ9DcF8NTMlkzlg6fj>H(jw4W(69PYvm3WSl zCwh-MNF3`H;o)32QLv2Bz13tSL2Q&*dfR$E_J(%n*z%{fb1ari83X&tBZhDf2ZJ& zYMT5}`$>PdfK`8G_}hd`lGNRRK=ro>kmO-TkT#U=U*L(T7N<^Je9E%PI+rt~xHzK2Yb%#T*3JlGL9ScUKz X$mz`FkM5n`M)kLWdRc}{lJxfv*1wG5 literal 0 HcmV?d00001 diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/build/default/production/main.o.d b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/build/default/production/main.o.d new file mode 100644 index 0000000..a491c02 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/build/default/production/main.o.d @@ -0,0 +1,55 @@ +build/default/production/main.o.d build/default/production/main.o: main.c \ + /opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/xc.h \ + /opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/cci.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/io.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/sfr_defs.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/inttypes.h \ + /opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/stdint.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/stdint.h \ + /home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10/include/avr/iotn10.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/portpins.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/common.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/version.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/xmega.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/fuse.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/lock.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/util/delay.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/util/delay_basic.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/math.h \ + /opt/microchip/xc8/v2.10/avr/avr/include/avr/interrupt.h + +/opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/xc.h: + +/opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/cci.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/io.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/sfr_defs.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/inttypes.h: + +/opt/microchip/xc8/v2.10/avr/lib/gcc/avr/5.4.0/include/stdint.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/stdint.h: + +/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10/include/avr/iotn10.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/portpins.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/common.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/version.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/xmega.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/fuse.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/lock.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/util/delay.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/util/delay_basic.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/math.h: + +/opt/microchip/xc8/v2.10/avr/avr/include/avr/interrupt.h: diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/memoryfile.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/memoryfile.xml new file mode 100644 index 0000000..be71962 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/memoryfile.xml @@ -0,0 +1,17 @@ + + + + + bytes + 1024 + 94 + 930 + + + bytes + 32 + 0 + 32 + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/tests7_timer_6000hz.X.production.elf b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/dist/default/production/tests7_timer_6000hz.X.production.elf new file mode 100755 index 0000000000000000000000000000000000000000..893bb0b8ebc733eeebd3718fc2977f078324fe66 GIT binary patch literal 5828 zcmbW5ZDTR<+=si%!4*oOP(xb+M{)np z?v6B`=0oY=oq3+$^UORmvoo_JzcMvDttblPNo5(vwGqI9U5ph_j<68;FzaRAu06{u zp!|yew4hY+bkxt(PuEY?Pu7R)L-iB&&;fEW4e*EO)hmRg=k6Hccn_C+j z_dmJM9zS~j=d4}uH<4K*Es{eZZC((+)&NNGlIXJ+ zqRBdtI%@GwL;Fx zK`NNHig|M^=Qzd6omdnkZ&hken9Si~C0w35q3{9%uB@zA z@=npJglnc-*1+8Gg6;;dIre(qfwi_~*-qH3te44my;3W#R?I>e=ZG!pIAd0dW~oqP zU1gjwdY(1Ao-}JW9jhA2TLm*>mJr#tD#d&)!e_!LS4+8N!!c`4gtFQN!zq?c+Zc^T zqic8d8}19_*@qBRrPb?5h&sZw^w0L#?6#*L4C#QE4Y@zf-6Y59}fEsj|J@b|HpJa>M;7x&Ku4-97wm zFqJJ(zHML;tLj9`jRXF6{$k|TSsd&U9O>>;tmI4U1(PxVoJ9*Yr+_0&U-RyyEh?Qp z+PI=!ZO4RR2D)HS1B#|SLuwOx%6d?73kmM840eUoA7HNOYDkG1rQ2G(TYI3!y8~}) z@$S~i9RuiBxKv!uhv)+oW&9+jGB%1MIi8$bx`8|~OIaoz_lilDOeND%76=}dNdHqGX*yBZa9Nw&C<&XU{G z6hb7^lWZ|Hj|_B@O{EfuKb4xxTthw$uLKC?u1q+aNTj22ubA|T1d91=lr6Xx$|o7B zMOl^_qGB4#4Ao>`OlGNPG+DH2gcN{G_g`ARxR-ktzzIkpPjhqZ74JRrucKglmZ*8& zXy=}5*08L^q~XpYCe6R%bEYx+MbbPzQ*v0 z6OzWT&5>w|C~0hmKLSq=u+1&1L3_+g3hUz{O0pk7Iox0hJK2yudldTB2HV`C-xOnl zJ_*_TRY7ob>l*SaB)VyHD}$2uf|oY83<$kkg?~eYK>aD9>VK0f@S*zOg)Y|rK6KhI zl*s=fbg}=BpwoQNdDMsX^GB)vN6;ty{Xq5q0iCB1bR2No;&ouKV*K5F@Tf%fk3tvY zM+LJZ8a1(Sjoy2(00y7EaMjL{FZIRnBhh@%t`??8PCQIw3=F&H)f~i zXR=hyGQqQn6yzc)O-!-lpc45elCh)3(>Eq&GX@1@gm>!sH08 zY%`vtdgx@$@7(M{;u`OT(7E)2+v~+SV_|waGnI9_=FKP{00UJ_>JJZzcN%zQk%l%9GQ?y%_?_-^7ZcX>B%ek-yAbp9sp$ zC%25!vAuGQOYU3N-ROGWDwj?Cl+z0)eqI|nJ6BmXYg{c>RxB>(mX~ew7T0LqaCrr5 zprIfL=e#X9UX1A#%Q5xU%DRp#4&u>|cP{`r=ozht7=m2nvbs^C2*j>03vM{35R8Wn|-aUWY87;t7%9CvKzfA(zQS_w1B# zHQ+Y-R&tsAUc_}FDqJzR?Mss1U0f4N+$h*^lik+dUpnajsLd4cMO*S4z$Ib#Gur!x z^uS14^R3E9BrO-oJODQ+KF6darZ`5SIsU vo9+?9bg|`r#(oaQ6CV +#include +#include + +#include +//#include +//#include +//#include + + + +//tests5 tested and works (at ~950hz). unplug cable to programmer to see pin 4 active. +//however... +//tests6 DEADEND +//never worked right. giving up and using delay. + +//reference: https://www.avrfreaks.net/forum/sample-project-attiny10 +//https://blog.podkalicki.com/attiny13-blinky-with-timer-compa/ +//watchdog is too slow and inaccurate to get 6000Hz + +//ISR(TIM0_COMPA_vect) +//{ +// // Toggle PB2 Hi/Low depending on current state +// PINB = 1<<2; +// TIFR0 |= 1< 256? (test) + + //520 about 950hz, 25us wide pulse + //OCR0A = 520; // with one timer, ever 166.667hz we want to count once (3000hz) + + //OCR0A = 1; //475hz + + //this goes to 475hz (pulses). doesn't make sense. +//// OCR0AH = 0xFF; // +//// OCR0AL = 0xFF; + + //attiny10 output compare broken apparently + //this still 960hz, with 100us or so pulse size (high is 100us, low is longer) + //OCR0A = 100; + + + //inline asm to load values into 16 bit register + + //; variables + //; For 1 Hz output, the timer delay has to be 1/2 second (1/2 second on / 1/2 second off) + //; delay = OCR0A * 1024 * 8 / 8000000 + //; for 1/2 second, OCR0A = 488 (0x01E8) + //.EQU OCR0AHigh = 0x01 + //.EQU OCR0ALow = 0xe8 + // in bash type: printf "%x\n" 488 + //.EQU OCR0AHigh = 0x02 + //.EQU OCR0ALow = 0x08 + + // ldi r17, OCR0AHigh //; Sets the output compare register value + //ldi r16, OCR0ALow + + //this asm doesn't work (why?) //perhaps OCR0A is really just 8 bits on attiny10...?) +////// asm volatile( +////// "ldi r17, 0x02" +////// "ldi r16, 0x08" +////// "out OCR0AH, r17" +////// "out OCR0AL, r16" +////// ); + + //this asm works +// asm volatile("nop\n\t" +//"nop\n\t" +//"nop\n\t" +//"nop\n\t" +//::); +//////// +//////// TIMSK0 |= _BV(OCIE0A); // enable Timer CTC interrupt +//////// + // PB2 change to output + DDRB = 1<<2; +//// sei(); + + + int x = 0; + while(1) + { + + //this goes about 60.3KHz. + //experiment FAIL + //will just buy a 6KHz oscillator. + + PINB = 1<<2; + //EDIT: disabled optimization in mplab (level 0) + //and ended up geting much slower IO + //asm("nop;"); + //for(x=0;x<2;x++){ + // asm("nop;""nop;""nop;""nop;""nop;" + //"nop;""nop;"//"nop;""nop;"//"nop;""nop;" + // ); + //}//just this asm block is about 121.22KHz + + } +} + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-default.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-default.mk new file mode 100644 index 0000000..f492a37 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-default.mk @@ -0,0 +1,158 @@ +# +# Generated Makefile - do not edit! +# +# Edit the Makefile in the project folder instead (../Makefile). Each target +# has a -pre and a -post target defined where you can add customized code. +# +# This makefile implements configuration specific macros and targets. + + +# Include project Makefile +ifeq "${IGNORE_LOCAL}" "TRUE" +# do not include local makefile. User is passing all local related variables already +else +include Makefile +# Include makefile containing local settings +ifeq "$(wildcard nbproject/Makefile-local-default.mk)" "nbproject/Makefile-local-default.mk" +include nbproject/Makefile-local-default.mk +endif +endif + +# Environment +MKDIR=mkdir -p +RM=rm -f +MV=mv +CP=cp + +# Macros +CND_CONF=default +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +IMAGE_TYPE=debug +OUTPUT_SUFFIX=elf +DEBUGGABLE_SUFFIX=elf +FINAL_IMAGE=dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +else +IMAGE_TYPE=production +OUTPUT_SUFFIX=hex +DEBUGGABLE_SUFFIX=elf +FINAL_IMAGE=dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +endif + +ifeq ($(COMPARE_BUILD), true) +COMPARISON_BUILD= +else +COMPARISON_BUILD= +endif + +ifdef SUB_IMAGE_ADDRESS + +else +SUB_IMAGE_ADDRESS_COMMAND= +endif + +# Object Directory +OBJECTDIR=build/${CND_CONF}/${IMAGE_TYPE} + +# Distribution Directory +DISTDIR=dist/${CND_CONF}/${IMAGE_TYPE} + +# Source Files Quoted if spaced +SOURCEFILES_QUOTED_IF_SPACED=main.c + +# Object Files Quoted if spaced +OBJECTFILES_QUOTED_IF_SPACED=${OBJECTDIR}/main.o +POSSIBLE_DEPFILES=${OBJECTDIR}/main.o.d + +# Object Files +OBJECTFILES=${OBJECTDIR}/main.o + +# Source Files +SOURCEFILES=main.c + + + +CFLAGS= +ASFLAGS= +LDLIBSOPTIONS= + +############# Tool locations ########################################## +# If you copy a project from one host to another, the path where the # +# compiler is installed may be different. # +# If you open this project with MPLAB X in the new host, this # +# makefile will be regenerated and the paths will be corrected. # +####################################################################### +# fixDeps replaces a bunch of sed/cat/printf statements that slow down the build +FIXDEPS=fixDeps + +.build-conf: ${BUILD_SUBPROJECTS} +ifneq ($(INFORMATION_MESSAGE), ) + @echo $(INFORMATION_MESSAGE) +endif + ${MAKE} -f nbproject/Makefile-default.mk dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} + +MP_PROCESSOR_OPTION=ATtiny10 +# ------------------------------------------------------------------------------------ +# Rules for buildStep: compile +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +${OBJECTDIR}/main.o: main.c nbproject/Makefile-${CND_CONF}.mk + @${MKDIR} "${OBJECTDIR}" + @${RM} ${OBJECTDIR}/main.o.d + @${RM} ${OBJECTDIR}/main.o + ${MP_CC} $(MP_EXTRA_CC_PRE) -mcpu=$(MP_PROCESSOR_OPTION) -c -D__DEBUG=1 -g -DDEBUG -gdwarf-2 -x c -D__$(MP_PROCESSOR_OPTION)__ -mdfp="/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10" -Wl,--gc-sections -O0 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -funsigned-char -funsigned-bitfields -Wall -DXPRJ_default=$(CND_CONF) $(COMPARISON_BUILD) -gdwarf-3 -MD -MP -MF "${OBJECTDIR}/main.o.d" -MT "${OBJECTDIR}/main.o.d" -MT ${OBJECTDIR}/main.o -o ${OBJECTDIR}/main.o main.c + +else +${OBJECTDIR}/main.o: main.c nbproject/Makefile-${CND_CONF}.mk + @${MKDIR} "${OBJECTDIR}" + @${RM} ${OBJECTDIR}/main.o.d + @${RM} ${OBJECTDIR}/main.o + ${MP_CC} $(MP_EXTRA_CC_PRE) -mcpu=$(MP_PROCESSOR_OPTION) -c -x c -D__$(MP_PROCESSOR_OPTION)__ -mdfp="/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10" -Wl,--gc-sections -O0 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -funsigned-char -funsigned-bitfields -Wall -DXPRJ_default=$(CND_CONF) $(COMPARISON_BUILD) -gdwarf-3 -MD -MP -MF "${OBJECTDIR}/main.o.d" -MT "${OBJECTDIR}/main.o.d" -MT ${OBJECTDIR}/main.o -o ${OBJECTDIR}/main.o main.c + +endif + +# ------------------------------------------------------------------------------------ +# Rules for buildStep: assemble +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +else +endif + +# ------------------------------------------------------------------------------------ +# Rules for buildStep: assembleWithPreprocess +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +else +endif + +# ------------------------------------------------------------------------------------ +# Rules for buildStep: link +ifeq ($(TYPE_IMAGE), DEBUG_RUN) +dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}: ${OBJECTFILES} nbproject/Makefile-${CND_CONF}.mk + @${MKDIR} dist/${CND_CONF}/${IMAGE_TYPE} + ${MP_CC} $(MP_EXTRA_LD_PRE) -mcpu=$(MP_PROCESSOR_OPTION) -Wl,-Map=dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.map -D__DEBUG=1 -DXPRJ_default=$(CND_CONF) -Wl,--defsym=__MPLAB_BUILD=1 -mdfp="/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10" -gdwarf-2 -Wl,--gc-sections -O0 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -funsigned-char -funsigned-bitfields -Wall -gdwarf-3 $(COMPARISON_BUILD) -Wl,--memorysummary,dist/${CND_CONF}/${IMAGE_TYPE}/memoryfile.xml -o dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX} -o dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} ${OBJECTFILES_QUOTED_IF_SPACED} -Wl,--start-group -Wl,-lm -Wl,--end-group -Wl,--defsym=__MPLAB_DEBUG=1,--defsym=__DEBUG=1 + @${RM} dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.hex + +else +dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX}: ${OBJECTFILES} nbproject/Makefile-${CND_CONF}.mk + @${MKDIR} dist/${CND_CONF}/${IMAGE_TYPE} + ${MP_CC} $(MP_EXTRA_LD_PRE) -mcpu=$(MP_PROCESSOR_OPTION) -Wl,-Map=dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.map -DXPRJ_default=$(CND_CONF) -Wl,--defsym=__MPLAB_BUILD=1 -mdfp="/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10" -Wl,--gc-sections -O0 -ffunction-sections -fdata-sections -fpack-struct -fshort-enums -funsigned-char -funsigned-bitfields -Wall -gdwarf-3 $(COMPARISON_BUILD) -Wl,--memorysummary,dist/${CND_CONF}/${IMAGE_TYPE}/memoryfile.xml -o dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX} -o dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX} ${OBJECTFILES_QUOTED_IF_SPACED} -Wl,--start-group -Wl,-lm -Wl,--end-group + ${MP_CC_DIR}/avr-objcopy -O ihex "dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${DEBUGGABLE_SUFFIX}" "dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.hex" +endif + + +# Subprojects +.build-subprojects: + + +# Subprojects +.clean-subprojects: + +# Clean Targets +.clean-conf: ${CLEAN_SUBPROJECTS} + ${RM} -r build/default + ${RM} -r dist/default + +# Enable dependency checking +.dep.inc: .depcheck-impl + +DEPFILES=$(shell "${PATH_TO_IDE_BIN}"mplabwildcard ${POSSIBLE_DEPFILES}) +ifneq (${DEPFILES},) +include ${DEPFILES} +endif diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-genesis.properties b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-genesis.properties new file mode 100644 index 0000000..77f7799 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-genesis.properties @@ -0,0 +1,10 @@ +# +#Wed Jul 15 02:31:35 EDT 2020 +default.Pack.dfplocation=/home/dev/.mchp_packs/Microchip/ATtiny_DFP/2.0.10 +default.languagetoolchain.dir=/opt/microchip/xc8/v2.10/bin +configurations-xml=0eecc53d82e1a001c204dd2d47a4259e +com-microchip-mplab-nbide-embedded-makeproject-MakeProject.md5=6e453b0cf7f7da72a932cfdb2f655401 +default.languagetoolchain.version=2.10 +host.platform=linux +conf.ids=default +default.com-microchip-mplab-nbide-toolchainXC8-XC8LanguageToolchain.md5=23d12c447ed4f9462f01e2202bc2f36a diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-impl.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-impl.mk new file mode 100644 index 0000000..b2822c5 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-impl.mk @@ -0,0 +1,69 @@ +# +# Generated Makefile - do not edit! +# +# Edit the Makefile in the project folder instead (../Makefile). Each target +# has a pre- and a post- target defined where you can add customization code. +# +# This makefile implements macros and targets common to all configurations. +# +# NOCDDL + + +# Building and Cleaning subprojects are done by default, but can be controlled with the SUB +# macro. If SUB=no, subprojects will not be built or cleaned. The following macro +# statements set BUILD_SUB-CONF and CLEAN_SUB-CONF to .build-reqprojects-conf +# and .clean-reqprojects-conf unless SUB has the value 'no' +SUB_no=NO +SUBPROJECTS=${SUB_${SUB}} +BUILD_SUBPROJECTS_=.build-subprojects +BUILD_SUBPROJECTS_NO= +BUILD_SUBPROJECTS=${BUILD_SUBPROJECTS_${SUBPROJECTS}} +CLEAN_SUBPROJECTS_=.clean-subprojects +CLEAN_SUBPROJECTS_NO= +CLEAN_SUBPROJECTS=${CLEAN_SUBPROJECTS_${SUBPROJECTS}} + + +# Project Name +PROJECTNAME=tests7_timer_6000hz.X + +# Active Configuration +DEFAULTCONF=default +CONF=${DEFAULTCONF} + +# All Configurations +ALLCONFS=default + + +# build +.build-impl: .build-pre + ${MAKE} -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .build-conf + + +# clean +.clean-impl: .clean-pre + ${MAKE} -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .clean-conf + +# clobber +.clobber-impl: .clobber-pre .depcheck-impl + ${MAKE} SUBPROJECTS=${SUBPROJECTS} CONF=default clean + + + +# all +.all-impl: .all-pre .depcheck-impl + ${MAKE} SUBPROJECTS=${SUBPROJECTS} CONF=default build + + + +# dependency checking support +.depcheck-impl: +# @echo "# This code depends on make tool being used" >.dep.inc +# @if [ -n "${MAKE_VERSION}" ]; then \ +# echo "DEPFILES=\$$(wildcard \$$(addsuffix .d, \$${OBJECTFILES}))" >>.dep.inc; \ +# echo "ifneq (\$${DEPFILES},)" >>.dep.inc; \ +# echo "include \$${DEPFILES}" >>.dep.inc; \ +# echo "endif" >>.dep.inc; \ +# else \ +# echo ".KEEP_STATE:" >>.dep.inc; \ +# echo ".KEEP_STATE_FILE:.make.state.\$${CONF}" >>.dep.inc; \ +# fi diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-local-default.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-local-default.mk new file mode 100644 index 0000000..62e3bb2 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-local-default.mk @@ -0,0 +1,36 @@ +# +# Generated Makefile - do not edit! +# +# +# This file contains information about the location of compilers and other tools. +# If you commmit this file into your revision control server, you will be able to +# to checkout the project and build it from the command line with make. However, +# if more than one person works on the same project, then this file might show +# conflicts since different users are bound to have compilers in different places. +# In that case you might choose to not commit this file and let MPLAB X recreate this file +# for each user. The disadvantage of not commiting this file is that you must run MPLAB X at +# least once so the file gets created and the project can be built. Finally, you can also +# avoid using this file at all if you are only building from the command line with make. +# You can invoke make with the values of the macros: +# $ makeMP_CC="/opt/microchip/mplabc30/v3.30c/bin/pic30-gcc" ... +# +PATH_TO_IDE_BIN=/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/ +# Adding MPLAB X bin directory to path. +PATH:=/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/:$(PATH) +# Path to java used to run MPLAB X when this makefile was created +MP_JAVA_PATH="/opt/microchip/mplabx/v5.25/sys/java/jre1.8.0_181/bin/" +OS_CURRENT="$(shell uname -s)" +MP_CC="/opt/microchip/xc8/v2.10/bin/xc8-cc" +# MP_CPPC is not defined +# MP_BC is not defined +MP_AS="/opt/microchip/xc8/v2.10/bin/xc8-cc" +MP_LD="/opt/microchip/xc8/v2.10/bin/xc8-cc" +MP_AR="/opt/microchip/xc8/v2.10/bin/xc8-ar" +DEP_GEN=${MP_JAVA_PATH}java -jar "/opt/microchip/mplabx/v5.25/mplab_platform/platform/../mplab_ide/modules/../../bin/extractobjectdependencies.jar" +MP_CC_DIR="/opt/microchip/xc8/v2.10/bin" +# MP_CPPC_DIR is not defined +# MP_BC_DIR is not defined +MP_AS_DIR="/opt/microchip/xc8/v2.10/bin" +MP_LD_DIR="/opt/microchip/xc8/v2.10/bin" +MP_AR_DIR="/opt/microchip/xc8/v2.10/bin" +# MP_BC_DIR is not defined diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-variables.mk b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-variables.mk new file mode 100644 index 0000000..a38ba2d --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Makefile-variables.mk @@ -0,0 +1,13 @@ +# +# Generated - do not edit! +# +# NOCDDL +# +CND_BASEDIR=`pwd` +# default configuration +CND_ARTIFACT_DIR_default=dist/default/production +CND_ARTIFACT_NAME_default=tests7_timer_6000hz.X.production.hex +CND_ARTIFACT_PATH_default=dist/default/production/tests7_timer_6000hz.X.production.hex +CND_PACKAGE_DIR_default=${CND_DISTDIR}/default/package +CND_PACKAGE_NAME_default=tests7timer6000hz.x.tar +CND_PACKAGE_PATH_default=${CND_DISTDIR}/default/package/tests7timer6000hz.x.tar diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Package-default.bash b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Package-default.bash new file mode 100644 index 0000000..d885e1c --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/Package-default.bash @@ -0,0 +1,73 @@ +#!/bin/bash -x + +# +# Generated - do not edit! +# + +# Macros +TOP=`pwd` +CND_CONF=default +CND_DISTDIR=dist +TMPDIR=build/${CND_CONF}/${IMAGE_TYPE}/tmp-packaging +TMPDIRNAME=tmp-packaging +OUTPUT_PATH=dist/${CND_CONF}/${IMAGE_TYPE}/tests7_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +OUTPUT_BASENAME=tests7_timer_6000hz.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} +PACKAGE_TOP_DIR=tests7timer6000hz.x/ + +# Functions +function checkReturnCode +{ + rc=$? + if [ $rc != 0 ] + then + exit $rc + fi +} +function makeDirectory +# $1 directory path +# $2 permission (optional) +{ + mkdir -p "$1" + checkReturnCode + if [ "$2" != "" ] + then + chmod $2 "$1" + checkReturnCode + fi +} +function copyFileToTmpDir +# $1 from-file path +# $2 to-file path +# $3 permission +{ + cp "$1" "$2" + checkReturnCode + if [ "$3" != "" ] + then + chmod $3 "$2" + checkReturnCode + fi +} + +# Setup +cd "${TOP}" +mkdir -p ${CND_DISTDIR}/${CND_CONF}/package +rm -rf ${TMPDIR} +mkdir -p ${TMPDIR} + +# Copy files and create directories and links +cd "${TOP}" +makeDirectory ${TMPDIR}/tests7timer6000hz.x/bin +copyFileToTmpDir "${OUTPUT_PATH}" "${TMPDIR}/${PACKAGE_TOP_DIR}bin/${OUTPUT_BASENAME}" 0755 + + +# Generate tar file +cd "${TOP}" +rm -f ${CND_DISTDIR}/${CND_CONF}/package/tests7timer6000hz.x.tar +cd ${TMPDIR} +tar -vcf ../../../../${CND_DISTDIR}/${CND_CONF}/package/tests7timer6000hz.x.tar * +checkReturnCode + +# Cleanup +cd "${TOP}" +rm -rf ${TMPDIR} diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/configurations.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/configurations.xml new file mode 100644 index 0000000..5255745 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/configurations.xml @@ -0,0 +1,160 @@ + + + + + + + + + main.c + + + Makefile + + + Makefile + + + + localhost + ATtiny10 + + + + XC8 + 2.10 + 2 + + + + + + + + + + + + + false + false + + + + + + + false + + false + + false + false + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/private/configurations.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/private/configurations.xml new file mode 100644 index 0000000..e61d739 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/private/configurations.xml @@ -0,0 +1,25 @@ + + + Makefile + 0 + + + + /opt/microchip/xc8/v2.10/bin + + place holder 1 + place holder 2 + + + + + true + 0 + 0 + 0 + + + + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/private/private.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/private/private.xml new file mode 100644 index 0000000..85e1734 --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/private/private.xml @@ -0,0 +1,9 @@ + + + + + + file:/home/dev/Desktop/code/electronics/attiny10_mplab_test/tests7_timer_6000hz.X/main.c + + + diff --git a/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/project.xml b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/project.xml new file mode 100644 index 0000000..e3ec1ac --- /dev/null +++ b/Attiny_Solar_Energy_Harvest/code/mplab/tests7_timer_6000hz_FAIL.X/nbproject/project.xml @@ -0,0 +1,35 @@ + + + com.microchip.mplab.nbide.embedded.makeproject + + + tests7_timer_6000hz + tests6_timer_6000hz + tests5_timer_6000hz + tests4_timer_6000hz + tests3 + tests2 + tests1 + test2 + test1 + 1f6b2f6c-8c6d-40dd-a737-d73d987b2bef + 0 + c + + + + ISO-8859-1 + + + + + default + 2 + + + + false + + + + diff --git a/Attiny_Solar_Energy_Harvest/docs/38.tex b/Attiny_Solar_Energy_Harvest/docs/38.tex index 06e8309..2d9ed28 100644 --- a/Attiny_Solar_Energy_Harvest/docs/38.tex +++ b/Attiny_Solar_Energy_Harvest/docs/38.tex @@ -412,6 +412,19 @@ From Programmer Source code: This programmer is not foolproof, so establish a routine, and keep a working model (pcb w/attiny) as a prototype to isolate what is broken. +\subsection{Attiny10 Timer Fail} +The goal was to get a 6KHz square wave out of the Attiny10 (first using the timer). After a night of trying to wrangle with timer 0 and CTC mode of the Attiny10 timer (which failed +to work as expected). I've decided to buy a 6KHz oscillator. I was able to get 60.3KHz +out of the Attiny using no optimization in mplab and IO as fast as possible. I was able +to get 6.13Khz using optimization and a for loop (unfortunately the nops got optimized out). + +I also learned that the cable I was using to program the attiny10 was giving me much trouble. +I ended up soldering one side to an uno. That out of the way, When programming the attiny10 +with my protoboard, it's as easy as, 1) connect cable to protoboard, 2) press P in serial monitor of Uno, +3) paste hex contents of mplab build into serial monitor. No need to ever reset the uno, even if +it doesn't print that it detects the attiny. It's pretty good about this, and if connected +correctly, will just write to the chip, when P is pressed. + \subsection{Further Notes} https://www.eevblog.com/forum/microcontrollers/powering-devices-via-gpio-pins/msg2720044/\#msg2720044 - Using GPIO to power devices.