Read the statement by Michael Teeuw here.
Config for clock not working
-
Hello folks,
I know I am doing something dumb. Everything else is working, though my clock is not taking the config: { section. I am trying to change it to 12 hour format (for WAF) and remove the seconds and add a lowercase am/pm.
Thanks for any suggestions and help!
Here is my config file :
/* Magic Mirror Config Sample * * By Michael Teeuw http://michaelteeuw.nl * MIT Licensed. */ var config = { port: 8080, language: 'en', units: 'Imperial', modules: [ { module: 'clock', position: 'top_left', config: { timeformat: 12, showPeriod: 'true', displaySeconds: 'false', } }, { module: 'alert', }, /* { module: 'MMM-wordnik', position: 'lower_third', config: { api_key: '', } }, */ { module: 'MMM-Traffic', position: 'top_left', classes: 'dimmed medium', //optional, default is 'bright medium', only applies to commute info not route_name config: { api_key: 'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx', mode: 'driving', origin: 'xxxxxxxxxxxxxxxxxxxxxxxx', destination: 'xxxxxxxxxxxxxxxxxxxxxxxxxx', route_name: 'Home to Work', changeColor: true, showGreen: false, limitYellow: 5, //Greater than 5% of journey time due to traffic limitRed: 20, //Greater than 20% of journey time due to traffic traffic_model: 'pessimistic', interval: 120000 //2 minutes } }, { module: 'MMM-Wunderlist', position: 'top_center', // This can be any of the regions. Best results in left or right regions. header: 'ToDo List', // This is optional config: { accessToken: 'xxxxxxxxxxxxxxxxxx', clientID: 'xxxxxxxxxxxxx', lists: ["inbox"], interval: 60, fade: true // See 'Configuration options' for more information. } }, { module: 'airquality', position: 'top_right', // you may choose any location config: { location: 'Philadelphia' // the location to check the index for } }, { module: 'calendar', header: 'Family Calendar', position: 'top_left', config: { calendars: [ { symbol: 'calendar-check-o ', url: 'webcal://calendar.google.com/calendar/ical/xxxxxxxxxxxxxxxxxxxxx/basic.ics' } ] } }, { module: 'compliments', position: 'lower_third' }, { module: 'currentweather', position: 'top_right', config: { location: 'Bristol, PA', appid: 'xxxxxxxxxxxxxxxxxxxxxx' } }, { module: 'weatherforecast', position: 'top_right', header: 'Weather Forecast', config: { location: 'Bristol, PA', appid: 'xxxxxxxxxxxxxxxxxxxxxx' } }, { module: 'newsfeed', position: 'bottom_bar', config: { feeds: [ { title: "ABC US Headlines", url: "http://feeds.abcnews.com/abcnews/usheadlines", }, { title: "Bristol News", url: "http://www.buckslocalnews.com/?rss=bristol_pilot/news", } ], showSourceTitle: true, showPublishDate: true } }, ] }; /*************** DO NOT EDIT THE LINE BELOW ***************/ if (typeof module !== 'undefined') {module.exports = config;}
Note from admin: Please use Markdown on code snippets so it is easier to read!
-
And the console error is? Or possibly it could also be in
'pm2 logs <YOUR_MM_TASK_NAME>'
… -
@KirAsh4 When I hit
<CTRL-M>
for the console (which is what I assume you mean) I doesn’t give any errors. Everything is working fine. It shows all the data correctly, but the clock is in 24 hour format. It’s almost like it’s just omitting the config section, and moving on. Though it says "No helper found for the module: clock. But I am pretty sure it always has said that.Thanks!
-
Had the same issue. Try removing the ’ marks before and after “true” or “false”
like this
config: { displaySeconds: false, }
worked for me ;)
Note from admin: Please use Markdown on code snippets!
-
yes true and false are booleans and no strings, so you need to remove the quotes
-
@strawberry-3-141 Try
timeFormat: 12,
instead oftimeformat: 12,
.Capitalization has gotten me more times that I can count.